Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.8.3
-
Fix Version/s: 1.9.3
-
Component/s: Zend_Filter_Input
-
Labels:None
Description
In Zend_Filter_Input the 'NotEmpty' Validator is always added to the validator chain.
We've defined :
$validator = array(
'street' => array (
new Zend_Validate_NotEmpty ( ),
new Zend_Validate_Regex ( '/^[a-zA-Z0-9\\xC0-\\xFF\`\'\/\.\-\s]{1,26}$/u' ),
new Zend_Validate_StringLength ( 0, 25 ),
Zend_Filter_Input::PRESENCE => Zend_Filter_Input::PRESENCE_REQUIRED,
Zend_Filter_Input::DEFAULT_VALUE => '',
Zend_Filter_Input::BREAK_CHAIN => true,
'messages' => array (
0 => 'Bitte geben Sie Ihre Straße ein.',
1 => 'Verwenden Sie bitte keine Sonderzeichen bei der Eingabe.',
array (
Zend_Validate_StringLength::TOO_LONG => 'Bitte beschränken Sie sich auf %max% Zeichen'
)
)
We would have the error message 0 if street is an empty param, instead of default 'notEmptyMessage'.
Issue Links
| This issue depends on: | ||||
| ZF-1912 | Message concurrency between options notEmptyMessage and Zend_Validate_Alpha::STRING_EMPTY |
|
|
|
Can you provide us with a full example ?
Your filter settings, calling method and input value so we get the same results.