• 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

reset button

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
for my login page, i have a reset button to clearup the loginname and password fields.

the reset button doesn't work,if the submit button is clicked.
In this case, the user can not logon and the errormessage occurs. In the loginname field the old value (the last value before i click the logon button) still exists. When i click the reset button, Nothing changes. When i fill a new value in the loginname field and click reset, the last value before i click the logon button occurs again.

in the userBean i add the methode

public void reset(){
setName("");
setPassword("");
}
in jsp site:
<h:commandButton id="reset" value="#{txt.reset}" action="#{user.reset}"/>

Can someone tell me why?
 
Mimi Cha
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have solved the problem by myself.
i just set the value of loginname="" by submitbutton.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic