I'm a little confused. Are you saying that with the second format, the
Validator client-side JavaScript validation fails and the server-side
validation works?
Angelo Luis <angelomysql@gmail.com>
08/29/2005 09:27 AM
Please respond to
"Jakarta Commons Users List" <commons-user@jakarta.apache.org>
To
commons-user@jakarta.apache.org
cc
Subject
[Validator] Decimal point and date
In my form this is work well:
<field property="date" depends="required,date">
<arg key="contrato.label.dtinicial" position="0"/>
<var>
<var-name>datePatternStrict</var-name>
<var-value>dd/MM/yyyy</var-value>
</var>
</field>
but, when i change to this:
<field property="date" depends="required,date">
<arg key="contrato.label.dtinicial" position="0"/>
<var>
<var-name>datePatternStrict</var-name>
<var-value>dd/MM/yy</var-value>
</var>
</field>
The validation don't work anymore... I type 19/09/05 he give me a wrong
date... I turn off the JavaScript in my browser and the server-side
validation work well, only the JavaScript validation give the wrong date
anwser!!!
The seond thing about validation is the decimal point separator!!! Both
server and client validation don't work with me!!!
That is what i do...
In my jsp page:
<html:html locale=true>
In my struts-config.xml
<controller nocache="true" locale="true" />
In my validations.xml
<formset country="BR" language="pt">
Am i forget something??
|