Hello, Again, thanks. Using HTTPClient I tried to upload a File to a HTTP Internet Information Server directory that I set up. HTTClient then gave a sensible error message:
Uploading filetoupload.txt to http://aika:80/uploads/ Upload failed, response=Method Not Allowed Shouldn't HTTClient do the same towards Tomcat when? I do not know whether Tomcat, HTTClient or both are to blaime: It maybe another lacking in the messy HTTP Protocol. The only way I know can check if Tomcat really did what it was supposed to do, is to parse the response and see if the file is present: Again a messy business, as there does not seem to be a standard format for the Directory Listing ! Or am I wrong? regards Geir Ove -----Original Message----- From: Oleg Kalnichevski [mailto:[EMAIL PROTECTED] Sent: 20. januar 2006 18:02 To: HttpClient User Discussion Subject: Re: MultipartFileUploadApp succeeds uploading file - but not upploaded Geir Ove Skjaervik wrote: > Hello, > > Thanks for the information: Trouble is, I did not know that Tomcat > needed "first aid" to be able to support uploadting files to the > server. > > > Any good tutorials for a Tomcat newbie (not Java newbie :-) ) on how > to setup FileUpload with Tomcat ? > This should get you started http://jakarta.apache.org/commons/fileupload/using.html http://www.theserverside.com/articles/article.tss?l=HttpClient_FileUploa d Oleg > Geir Ove > > -----Original Message----- > From: Oleg Kalnichevski [mailto:[EMAIL PROTECTED] > Sent: 20. januar 2006 17:38 > To: HttpClient User Discussion > Subject: Re: MultipartFileUploadApp succeeds uploading file - but not > upploaded > > > Geir Ove Skjaervik wrote: > >>Hello, >> >>I have now used days seraching the net for a solution to this problem. > > >>Please help. >> >>I am running Tomcat 5.5 locally on my computer under Windows XP Pro. I > > >>am trying to upload a simple 1 line text file to the server to a >>directory called "uploads" located directly under ROOT. >> >>I am uses the Jakarta HTTPClient and the MultipartFileUploadApp >>example to do this. The "uploads" directory is not username / password >>protected: I have successfully downloaded contents of files from this > > >>directory using a simple Http Connection in a Java program. >> >>MultipartFileUploadApp says the upload succeded, and returns the >>Server >>(Tomcat) response which is simply Html that lists the contents of the >>"uploads" directory: It does NOT contain the file I tried to uplad. >>Checking the directory in the FIle Explorer confirms the file is not >>there. >> >>Is there any settings in Tomcat server.xml or web.xml for the >>"uploads" directory that must be set to allow uploads ? If so which? >> >>In your reply, please consider that I am not an expert Tomcat user ! >> > > > Geir Ove, > Tomcat as well as many other servlet containers do not provide support > for multipart/form-data encoded content out of the box. One needs a > special library to parse multipart uploads, such as Jakarta Commons > FileUpload. What library are you using, if any? > > Oleg > > >>Thanks in advance for all help ! >> >> >>regards >> >>Geir Ove >> >>Norway >> >> >> > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
