This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JSF and file upload  RSS feed

 
Yuri Sforza
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How JSF handles file uploads (i.e. forms submitted with multipart/form-data encoding)? What if there are "normal" parameters (key=value pairs) sent together with file data, will they be lost for further processing?
TIA
--
Y. Sforza
 
Bill Dudney
Author
Ranch Hand
Posts: 234
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Although its not in the spec I seem to remember an open source component to do this. JSF does not make the web invisible, file up load works the same way it would with Struts or other frameworks.
Hope this helps!
 
Nicholas Cheung
Ranch Hand
Posts: 4982
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I dont know how JSF works.
But Struts works fine. It provides a standard JSTL for composing the form, and when the form is submitted, the file will be uploaded and the control will be passed the the DispatchAction class. In this class, the uploaded file is already stored somewhere inside the Web server, and you can still, use the file handler to save the uploaded file to the *target* location, after that, the temp. file can be destroyed.
I guess JSF has such a similar framework, just like what the past *JSPSmartUpload* utility.
Nick.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!