Uploading a File with enctype=multipart/form-data and com.oreilly.servlet
Posted on 2004-08-12
I had a JSP with a form that DID use "method=POST" and DID NOT use "enctype=multipart/form-data" and itworked beautifully. - Now I need to upload a file in the same form.
I figured out how to use com.oreilly.servlet in a simple form that DID use "enctype=multipart/form-data"
But now I have tried to combine the two forms.
When I add "enctype=multipart/form-data" to the original form, all of my fields are null.
1.) I need to use "method=post" because there is too much data to include in a URL for the get method
2.) Someone said that with "enctype=multipart/form-data" that JSP/servlets do not support the use of .getParameter() or that I need to "decode the request to get at the parameters and contents" of the form
3.) I would really like to use the com.oreilly.servlet package since I already got it to work and it is so simple.
So how can I pull all of the form data out of the form using POST and "enctype=multipart/form-data"?
Thanks in Advance,