struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martin Gainty (JIRA)" <>
Subject [jira] Created: (WW-2408) date-validator broken
Date Tue, 08 Jan 2008 16:16:05 GMT
date-validator broken

                 Key: WW-2408
             Project: Struts 2
          Issue Type: Bug
          Components: XML Validators
    Affects Versions: 2.0.11
         Environment: wintel 
Java HotSpot(TM) Client VM (build 1.5.0_02-b09, mixed mode)
TC 5.5.17

            Reporter: Martin Gainty
            Priority: Minor

	<package name="validation" extends="struts-default" namespace="/validation">
	    <action name="quizBasic" class="org.apache.struts2.showcase.validation.QuizAction">
            <result name="input">quiz-basic.jsp</result>

where quizBasic.jsp contains the following form
<s:form method="post">
    <s:textfield label="Name" name="name"/>
    <s:textfield label="Age" name="age"/>
    <s:textfield label="Favorite color" name="answer"/>
    <s:textfield label="date" name="date"/>

following instructions for configuration of date-validator from tim jee at

QuizAction-validation.xml contains the following 
    <field name="name">
        <field-validator type="requiredstring">
            <message>You must enter a name</message>
    <field name="age">
        <field-validator type="int">
            <param name="min">13</param>
            <param name="max">19</param>
            <message>Only people ages 13 to 19 may take this quiz</message>
    <field name="date">
	 <field-validator type="date">
		 <param name="min">01/01/1900</param>
		 <param name="max">01/01/2099</param>
		 <message>invalid date</message>

will pass any date thru 

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message