struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Jouravlev" <jmi...@gmail.com>
Subject Re: Action based client validation
Date Wed, 06 Sep 2006 16:06:25 GMT
On 9/6/06, Vaylee Mckenzie-Daniels (VA) <MckenzVA@telkom.co.za> wrote:
>
>
>
> > I am struggling to find resources on how to enable the validation
> > only when submit is selected. Validation should not be done when
> > cancel is selected.

If you use JSP for the view part of your app, then use <html:cancel>
to render Cancel button. The key that it submits is processed by
Struts as cancel action and no validation is performed (launch HTTP
sniffer to see value submitted by cancel button).

Or you can turn autovalidation off and validate input data whenever you need.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message