This week's book giveaways are in the AI and JavaScript forums.
We're giving away four copies each of GANs in Action and WebAssembly in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of GANs in ActionE this week in the AI forum
or WebAssembly in Action in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
  • Knute Snortum
Sheriffs:
  • Liutauras Vilda
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Joe Ess
  • salvin francis
  • fred rosenberger

question about ENCTYPE="multipart/form-data" page

 
Ranch Hand
Posts: 119
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi experts , I have a form page containing (ENCTYPE="multipart/form-data" ) to upload files . But the problem is when I
read field attribute using request.getParameter("Name"); it returns null , and i am sure about the name of field attribute , so in order to avoid this null I have to erase
(ENCTYPE="multipart/form-data) from my page . I don't want to erase it , because I am uploading files from the page , what is the solution , how can I upload files and get values
of fields in same page

thanks in advance
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You need to use a multipart request library, like Apache's commons-fileupload or similar. Please see the file upload FAQ entry.
 
alsoumahi alBatal
Ranch Hand
Posts: 119
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

David Newton wrote:You need to use a multipart request library, like Apache's commons-fileupload or similar. Please see the file upload FAQ entry.



thanks a lot but is there any like to see examples how to use this class "multipart request" , because I am new to this class , I have tried but I got errors
thanks a lot
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
...

The documentation?

http://commons.apache.org/fileupload/using.html
 
Then YOU must do the pig's work! Read this tiny ad. READ IT!
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!