commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Niall Pemberton" <niall.pember...@blueyonder.co.uk>
Subject Re: Arg1 not being replaced in validator?
Date Tue, 21 Mar 2006 19:06:46 GMT
What version of validator are you using? There was a problem in Validator
1.2.0, using the arg0 - arg1 format. If your using that version, try
replacing it with <arg position=""...>

<arg position="1" key="${var:minlength}" name="minlength" resource="false"/>

Niall

----- Original Message ----- 
From: "Alluri, Ramakrishna" <Ramakrishna.Alluri@compucredit.com>
Sent: Tuesday, March 21, 2006 6:55 PM


I am using struts common validator for validating required, minlength
and maxlength for the fields

However, I see that arg1 is not being replaced with the value. Here is
the example:

<field property="solicitationNbr" depends="required,integer,minlength">

<arg0 key="solicitationNbr"/>

<arg1 key="${var:minlength}" name="minlength" resource="false"/>

<var><var-name>minlength</var-name><var-value>12</var-value></var>

</field>



However, I get the following message

solicitationNbr can not be less than null characters. Any idea why {1}
is not being substituted with number '12' ?



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


Mime
View raw message