Win a copy of Svelte and Sapper in Action this week 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
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

html:file tag

 
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am building an application using tomcat and struts framework.
I am facing a strange problem in implementing html:file tag. under normal circumstances i am able to upload the file without any problems. now suppose i have a form of few other fields like text, checkbox, etc., and including the file field. If someone enters an invalid field. i do a server side validation and take the user back to the form page so that they can re-enter the invalid field. the rest of the field stay populated as expected but the file field becomes empty. which is not the behaviour i want. The file field should remain populated with the file i selected in my file open dialog box. is this a normal behaviour with html:file or am i missing something. My html file tag looks as follows.
<html:file property="resumeFile" name="resourceForm"/>
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
i have also same problem.
any 1 know the answer?
 
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
no body,
We don't have many rules at Javaranch, but our naming policy is one of them. Please read this policy and change your display name to comply with it if you wish to continue posting. Thanks.
You can change your display name here.
 
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That is normal behaviour of html file tag.
Try sending selected location back to the form.
http://lists.w3.org/Archives/Public/www-html/1994Sep/0051.html
 
I will suppress my every urge. But not this shameless plug:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic