Hi Jeff..

This is what you need to do:
1. Define a form bean which extends ValidatorActionForm 
2. Define a action in which you use this form bean.  (suppose /myAction)

And in the validator.xml you need to do
<form name="/myAction">   <--- the action that uses the formbean
   <field property = "beanProperty1"  <--- a property that you want 
          depends="validator1"             to validate in form bean
        ...
   </field>
</form>

Note that if you have another action defined using the same form bean..
<form name="/myAction2">
   <field property= "beanProperty1"
          depends="validator2"   <--note you can have different 
                                    validation rule applying to the
                                    same bean property
              ...
</form>

A thing to remember if you are doing client side validation...
<html:javascript formname="/myAction" method="myActionMethod"/>
The formname needs to map exactly to the form name... (including the slash)
and because of the slash, the default generated name is invalid javascript.. so you 
need to use "method =" to specify the generated 
method.

Hope this helps.

Ying

__________________________________________________________________
The NEW Netscape 7.0 browser is now available. Upgrade now! 
http://channels.netscape.com/ns/browsers/download.jsp 

Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/

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

Reply via email to