ZF-8768: Zend_Validate_GreaterThan does not accept $options in array() anymore


Zend_Form::addElement is giving it's validators options in a form of array(). But Zend_Validate_GreaterThan does not process array() given as parameter to constructor. It honors Zend_Config instance now only.


Here's a patch that fixes the problem.

Please give some reproducable informations...

Which release are you refering to? How did you initialise the validator?

Seems to duplicate ZF-7153

Being unable to reproduce didn't stop you from merging my fix to Zend_Validate_GreaterThan and other Validators in SVN r20182.

You have really bizarre development practices in Zend Framework making me doubt the framework credibility.

$ svn log -c20182 library/Zend/

r20182 | thomas | 2010-01-10 22:12:01 +0100 (nie) | 3 linie

[ZF-7153] Zend_Validate:

- added missing classes

$ svn diff -c20182 library/Zend/Validate/GreaterThan.php

Index: library/Zend/Validate/GreaterThan.php

--- library/Zend/Validate/GreaterThan.php (wersja 20181) +++ library/Zend/Validate/GreaterThan.php (wersja 20182) @@ -66,6 +66,9 @@ { if ($min instanceof Zend_Config) { $min = $min->toArray(); + } + + if (is_array($min)) { if (array_key_exists('min', $min)) { $min = $min['min']; } else {

Fixed with r20182

Note: This issue was NOT CLOSED as unreproducable. It was linked to an older issue which was not fixed.

You may also note that this revision targeted much more things which you did not mention in this issue.

I'm sorry that you have problems with me fixing issues that fast. Normally users appreciate such a fast response.