You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Sonu S <so...@gmail.com> on 2006/08/27 13:53:58 UTC

email valodation

 hi all,


i am using struts' validation.

i want to validate fields for required, mask and email. required and mask
validation works fine but email validation is not working.....it gives error
like....


validateEmail method not found......

 i have given


<!--validation.xml-->

<form name="Form">

<field property="email" depends="email">

<arg0 key="Form.email" />

</field>

</form>

</formset>

</form-validation>



<!--validator-rules.xml-->

<validator name="email"

classname="org.apache.struts.validator.FieldChecks"

method="validateEmail"

methodParams="java.lang.Object,

org.apache.commons.validator.ValidatorAction,

org.apache.commons.validator.Field,

org.apache.struts.action.ActionMessages,

org.apache.commons.validator.Validator,

javax.servlet.http.HttpServletRequest"

depends=""

msg="errors.email"/>


pls tell me how to do the email validation

thank you

with regards