Hi
This code works fine with ZF 1.9.2 but not with latest trunk.
$startdate = new Zend_Form_Element_Text('startdate');
$startdate->setLabel('Start date:')
->addValidator(
'Date', true, array(
'messages' => array(
'dateInvalidDate' => 'Invalid date',
'dateNotYYYY-MM-DD' => 'Invalid format'
)
)
)
->setAttrib('size', 10)
->setAttrib('maxLength', 10)
->setRequired(true);
With latest trunk it throws a fatal error when the form is submitted.
Fatal error: Uncaught exception 'Zend_Validate_Exception' with message 'No
message template exists for key 'dateNotYYYY-MM-DD''
in
C:\wwwroot\lib\php\ZendFramework\library\Zend\Validate\Abstract.php:153...
Is it a bug or something that has changed ?
Cheers
Holo