Hi ,
I want to do a validation of password length specifying minlength should be 15 ,i am using struts validtion.xml to do this,i am able to validate required fields but not length ,where i am going wrong.The code is like
validation.xml
<formset>
<form name="LoginForm">
<field property="password" depends="required,minlen">
<arg key="label.password" position="0"/>
<arg key="${var:minlen}" resource="false" />
<var>
<var-name>minlen</var-name>
<var-value>3</var-value>
</var>
</field>
<field property="userName" depends="required">
<arg key="label.userName" position="0"/>
</field>
</form>
</formset>
jsp is like
<html:form action="/Login?method=login">
<body>
<table cellspacing="0" cellpadding="0" borde="0" style="width:300px;text-align:left;">
<tr><td colspan=2><html:errors /></td></tr>
<tr>
<th><bean:message key="label.userName"/></th>
<td><html:text name="LoginForm" property="userName" /></td>
</tr>
<tr>
<th><bean:message key="label.password"/></th>
<td><html:password name="LoginForm" property="password" /></td>
</tr>
<tr>
<td colspan="2"> </td>
</tr>
<tr>
<td colspan="2" align="center"><html:submit styleClass="submit" value="Login" style="width:60px; text-align:center"/></td>
</tr>
</table>
</body>
</html:form>
Please tel me how to do this ?