RE: [PEAR-DEV] projecthoneypot

From: Date: Fri, 13 Mar 2009 20:00:32 +0000
Subject: RE: [PEAR-DEV] projecthoneypot
References: 1 2 3 4 5 6  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-51621@lists.php.net to get a copy of this message
>> Description: >> ------------ >> The docs says: >> "To validate a group as a whole, just use HTML_QuickForm::addRule(). The >> group elements' values will be passed to the validation function as an >> array." >> >> Actual result: >> -------------- >> All values of group elements passed to validation function as an array on >> RuleRegistry.php:158. >In the other words, it behaves exactly as described in documentation. Where is >the bug? Ok than, I misunderstood documentation. This part: "Groups of elements can be validated the same way other elements are, or use a more complex validation scheme. To validate a group as a whole, just use HTML_QuickForm::addRule(). The group elements' values will be passed to the validation function as an array." The words "the same way" and "just use HTML_QuickForm::addRule()" tangled me up, I thought built in rules should work the same way, just for all elements of a group. May be than some words about user have to implement his own callback to use with a group and that built in rules won't work should be added to documentation? - Boris

« previous php.pear.dev (#51621) next »