<field property="phone" depends="requiredif">
                                <arg0 key="venue.phone" />
                                <var>
                                        <var-name>field[0]</var-name>
                                        <var-value>venueId</var-value>
                                </var>
                                <var>
        
<var-name>field-test[0]</var-name>
                                        <var-value>EQUAL</var-value>
                                </var>                          
                                <var>
        
<var-name>field-value[0]</var-name>
                                        <var-value>0</var-value>
                                </var>                  
                        </field>

here is an example where phone is required if venueId is EQUAL to 0.
There are couple of other options for the kind of test just look it up
in FiledsCheck validator.

> -----Original Message-----
> From: georgehill [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, August 06, 2003 11:35 PM
> To: [EMAIL PROTECTED]
> Subject: how to use requiredif
> 
> Hi all,
> 
> I hava question about the use of required in the validation.xml
file.My
> example is :
>       <field property="conPassword" depends="requiredif">
>         <arg0 key="prompt.confirm.password"/>
>         <var>
>           <var-name>test</var-name>
>           <var-value>((newPassword != null)</var-value>
>         </var>
>       </field>
> Is it right? If it's wrong, please give me a right example.
> Thanks a lot. :)



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to