Results 1 to 2 of 2
- 11-26-2008, 06:08 AM #1
Member
- Join Date
- Nov 2008
- Posts
- 1
- Rep Power
- 0
Problem in reading HTML input field while uploading file
When i use multipart/form-data as my form enctype, then i have problem in reading html input field value.
i.e. Assume that i have following HTML Form
<form name="frmFileUpload" enctype="multipart/form-data" method="post">
<input type="text" name="txtName">
<input type="file" name="uploadFile">
<input type="submit" name="butSubmit" value ="Upload">
</form>
And, here i am tring to read txtName input field value using follwoing code fragment in my ApplicationController
request.getParameter("txtName")
this gives me null value.
Let me know, how do i read the input field value when Form's enctype type is multipart/form-data
thanks
nt anandLast edited by sudipanand; 11-26-2008 at 07:24 AM.
- 11-27-2008, 09:26 AM #2
getParameter is documented to work on either post data or get data, code above looks correct to me.
Where is this running?Introduction to Programming Using Java.
Cybercartography: A new theoretical construct proposed by D.R. Fraser Taylor
Similar Threads
-
uploading a file
By itssiva in forum Java ServletReplies: 4Last Post: 01-16-2009, 10:41 AM -
Reading input file into an array
By littlefire in forum New To JavaReplies: 6Last Post: 10-18-2008, 11:51 PM -
File Uploading
By aaliadhurue in forum Advanced JavaReplies: 4Last Post: 01-16-2008, 06:56 PM -
Reading a Field in a Binary File
By janakiram.attuluri in forum Advanced JavaReplies: 2Last Post: 01-09-2008, 10:47 AM -
Problem reading an xml file with AJAX
By Fiona80 in forum XMLReplies: 0Last Post: 12-17-2007, 08:02 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks