• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

JSF and file upload

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Author
Posts: 234
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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!
 
Ranch Hand
Posts: 4982
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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.
 
rubbery bacon. rubbery tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic