File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other Open Source Projects and the fly likes Apache commons file upload Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Products » Other Open Source Projects
Reply Bookmark "Apache commons file upload" Watch "Apache commons file upload" New topic
Author

Apache commons file upload

Noopur Kore
Ranch Hand

Joined: Aug 18, 2012
Posts: 77

Here I'm trying to upload a file and write it's content in my JSP. Here's my code :

Here my string file appears to be empty. Can someone please tell me where am I going wrong?
Because while debugging I can see the file being uploaded to the servlet but I'm unable to retrieve contents of the file. Please help.
Noopur Kore
Ranch Hand

Joined: Aug 18, 2012
Posts: 77



I got this code from my friend. Can someone please help me in understanding how this while loop is working?
Swastik Dey
Ranch Hand

Joined: Jan 08, 2009
Posts: 1195



The iterator above is collection of objects retrieved in request object. Then you are iterating through that collection using the loop, and comparing the type of object i.e whether its a form field (text,checkbox,radio etc) or a file type object i.e input type=file.


Swastik
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Apache commons file upload
 
Similar Threads
upload.parseRequest(request); giving null.
How to display all headers of multipart request?
Accepting File Uploads to Server
Submit multipart and form data
request.getParameter() returns null