I'm trying to valitade a time field in a form using Struts-validator (Struts 1.2). This is how I've configured validation.xml: <form ....> ... <field property="time" depends="required,date"> <arg0 key="test.time"/> <var> <var-name>datePattern</var-name> <var-value>HH:mm</var-value> </var> </field> ... </form>
The problem is that the validator always raises an validation error, no matter what data is informed, for example, like this 13:00.
Is my validation.xml correct? How do I validate a Time field?