Help coderanch get a
new server
by contributing to the fundraiser
  • 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Not able to persist the absolute path of selected file in file upload control.

 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm having JSP page where I need to upload few images. while doing the form validation, I'm able to get the selected file Path but, I also want to persist the selected path in the form field.
But I'm not able to persist the absolute path of selected file in file upload control. Is this possible?
My code snippet is:
<input type="file" name="fileUplCtrl" size="20">
I even tried providing a static value to uploadControl. But still the value is not persisting.
<input type="file" name="fileUplCtrl" value="c:/
abc.gif" size="20" >
If somebody had faced the same problem. Please suggest. Any help will be appreciated.
regards
abhilesh
 
Ranch Hand
Posts: 114
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
it is not possible to give any predefined value to "input type=file" for security reasons. as you do not have any rights on client machine.
if you want.. then use activex controls, this is the only way.
 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Send me the full code of the file then i will try to help u
Thanks
boddepalli@yahoo.com
 
Space pants. Tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/t/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic