Details
Description
using Zend_Date::isDate() with format. Unexpected result:
$bool = Zend_Date::isDate("1s1-2008", 'MM-yyyy');
Zend_Debug::dump($bool);
result:
bool(true)
I assume this is a bug ?!
using Zend_Date::isDate() with format. Unexpected result:
$bool = Zend_Date::isDate("1s1-2008", 'MM-yyyy');
Zend_Debug::dump($bool);
result:
bool(true)
I assume this is a bug ?!
|
|
|
No, because 1-2008 is a date according to MM-yyyy.
Leading and following parts are stripped as this only checks if Zend_Date can handle this date.
Use additionally regex or string-length validator when you have to limit the date to a stricter value.