how to stop form submission in <h:commandButton>
843844Sep 7 2009 — edited Sep 8 2009Hi
I have a <h:commandButton> within my form. I tried attaching a javascript handler for 'onclick' event of the button.
In the javascript method, i validate a field in form and stop the form submission in the onclick.
But i am not able to do it. All times form is getting submitted.( i do not want to go for trinidad for client side form validations )
How can i achieve, to stop the form submission, if i use <h:commandButton>
Thanks
-vijay