Thanks Geoff Well, yes, I actually started going thru the mail lists and found your link below. It is helpful, but I cannot get some of the features to work. I DO have the FilePartFile bit working, though I would not like to store such files on the disk.
I gave these two init params: <init-param> <param-name>autosave-uploads</param-name> <param-value>false</param-value> </init-param> <init-param> <param-name>overwrite-uploads</param-name> <param-value>allow</param-value> </init-param> I basically want to keep them in memory, and then use a FilePartArray to save the file contents into the database, but I am having trouble with that. Cocoon does not seem to be recognizing these parameters. Incidentally, I am using 2.0.4, and I built it under java1.4. I put the <init-param>s with the other init-params in web.xml, but strangely did not see any places for it in the web.xml file as it existed. I thouight there would be placeholders for it, but I could not find them. Anyways, I might be missing something. My main problem now is that when I submit a file multiple times, it keeps renaming the file 0_[filename], 1_[filename], etc.. I think my workaround will be to just delete the file once I am done with it, but I would like to keep it in memory if at all possible. Thanks very much for your help! Collin ----- Original Message ----- From: "Geoff Howard" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, January 20, 2003 4:01 PM Subject: RE: Parsing multipart form data > Have you seen this document yet? > http://wiki.cocoondev.org/Wiki.jsp?page=FileUploadsWithCocoon. I'm sorry if > it's not written very clearly - I wrote it late at night sort of > spontaneously. > > That gives some basic information on how cocoon handles things behind the > scenes. The important part in your case is that you don't need to do the > multipart parsing - it's already done for you by the time your action gets > on the scene. You can then use the FilePart object to get the contents of > the file via an InputStream and do whatever you want with it. > > If that doesn't help, give more of an idea of what you need to do on the > backend. > > Geoff Howard > > -----Original Message----- > From: Collin VanDyck [mailto:[EMAIL PROTECTED]] > Sent: Monday, January 20, 2003 3:36 PM > To: [EMAIL PROTECTED] > Subject: Parsing multipart form data > > > Hi, > > I'm trying to figure out the best way to parse multi-part form data. I have > a page which submits to a certain URI which invokes an action. This action > needs to parse the multi-part form data (in the request object I believe) > and then pass that data off to my j2ee backend for processing. > > My problem is that I do not see a way for me to create this MultipartParser > or what not. The Cocoon request object does not as I understand it, provide > a way for me to get the necessary data to create this parser (i.e. I need a > HttpServletRequest), and since my editor does not implement the servlet > interface, it does not receive the Request object from the servlet container > as a parameter (i.e. doAction, etc). > > I feel like I am possibly barking up the wrong tree here. Is the action the > appropriate place to do this? Should I instead implement a matcher to find > this request object? > > thanks, > Collin > > ---- > Collin VanDyck > AOL: djtcl > Yahoo: webcollin > > > --------------------------------------------------------------------- > Please check that your question has not already been answered in the > FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> > > To unsubscribe, e-mail: <[EMAIL PROTECTED]> > For additional commands, e-mail: <[EMAIL PROTECTED]> > --------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>