You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by N G <ni...@gmail.com> on 2005/05/31 22:36:37 UTC

Automatic validation question...

If I have set up validation as follows:

<field property="myField" depends="validwhen, required">
      <arg0 key="myForm.FirstName"/>
        <var>
          <var-name>test</var-name>
          <var-value>(radioButton = "firstNameSearch")var-value>
        </var>
</field>

If "validwhen" failts, will it try to validate the "required"?

In other words, when using automatic validation, the validator goes
through the list in "depends" and quits as soon as something is not
valid or does it keep going?

Also, does my "validwhen" look right? I have different types of
searches on my form and depending on which search (radio button) the
user clicks, different fields are required. So, if the user clicks on
"First Name Search", the first name field will be required. Did I set
it up correctly?

Thanks,
NG.

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