I have four components in my html form(enctype="multipart/form-data").First two components are text fields of "text" type and third one is of "file" type(for file uploading)and a "submission Button".When i am recieving the data of html form on a jsp page using the "request" object, it is giving NULL values for first two fields.I store the recieved data into table "photogallery(photoid,description,photo)" using the database-SQL Server 2000. What could be the probable solution for this? Below is the coding that for jsp file:
The request object does not know how to parse multi-part requests, which is why you are getting null values.
Parsing a multi-part request is a complicated affair and, rather than trying to do it yourself, you'd be better served by using one of the libraries that have already solved the problem for you. See the JSP FAQ on file uploading for more details.