You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Michael O'Connor <m....@finalist.com> on 2003/04/18 21:33:22 UTC

proposed solution Bug19161 (validateDate in validation-rules.xml)

Hi,

This is a first-time post, so please excuse (and feel free to point out) any
transgressions of protocol on my part.

I'm developing an application with the validation framework and the 1.1-rc
version of struts, and noticed that the javascript validation doesn't work
for 'lenient' date formats (e.g. datePattern = "dd/MM/yyyy", which accepts
1/1/2003) - only the strict validation works (e.g. datePatternStrict =
"dd/MM/yyyy" which only accepts 01/01/2003).  The server-side validation
does work for lenient datePatterns, I'm only talking about the client-side
validation here.

I searched Bugzilla and only saw a related bug 13239, that validateDate
won't validate uncommon formats such as "yyyy/MM".

I've submitted a solution (the patch is attached to the 19161 bug report),
which solves both problems (for me ;).

Hope this is useful!

-------------------------------------
Michael O'Connor
Senior Java Developer

Finalist IT Group / Java Specialists
P.O. Box 1354
3000 BJ Rotterdam
The Netherlands                 
Office: +31 10 217 08 36 (Direct)+31 6 15441087
m.oconnor@finalist.com
http://www.finalist.com
-------------------------------------


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