• 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:
  • Tim Cooke
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Jesse Silverman
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Al Hobbs
  • salvin francis

File browser button

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying to design a form which takes as input a file name. I am not upload this file just storing the file name within a database. I would like to allow the user
to browse to the file to ensure the filename is correct. If I were using plain HTML I could use <input type="file"> . However, this is embedded in a a4j:form which is
doing other things. Is there a JSF component similiar to input type="file"? or is there another way to do this? below is an example of the current working code. It is
using the <h:inputText> tag top capture the file name. I've highlighted the code below with ****** on the line in question.

Joe


 
Marshal
Posts: 26912
82
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Joe, welcome to the Ranch!

Just one thing about posting... when you post code, it's nice for it to be formatted. That's why we have the "Code" button above the posting box. If you click it, you'll see a pair of tags appear. If you paste your code between those tags then it comes out nicely formatted. I've edited your post to do that.
 
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello

<webuijsf:upload binding="#{ThemeAdmin.rightImageFile}" id="rightImageFile" /> (work like input type="file")

need to add xmlns:webuijsf="http://www.sun.com/webui/webuijsf"

thnks
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic