Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Reset button in JSF

843844Feb 21 2008 — edited Feb 15 2010
Hi,

I have a <h:form> which has some validation too. I want to add a "reset button" that will clear all the feilds in the form.

I have used the <h:commadButton type="reset" value="Reset" /> in the form. After filling the form the user clicks on Reset button and all the fields are cleared.
But if the form is submitted and the user fails the validataion and now clicks on the "Reset" button it cannot clear the values in the form fields.
How can I get this accomplished.

Regards

Sandeep
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 15 2010
Added on Feb 21 2008
9 comments
537 views