Re: QF - addGroupRule() on custom function
| From: | Alexey Borzov | Date: | Tue, 14 Oct 2003 14:22:02 +0000 |
| Subject: | Re: QF - addGroupRule() on custom function | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-8428@lists.php.net to get a copy of this message | ||
Hi!
Ignatius Reilly wrote:
Hello, I have a group of elements [scengroup][1] ... [scengroup][n] I wish to validate each element individually against a custom function "ok_values". The doc says: "To validate grouped elements as separate entities, use addGroupRule()." I have tried: $form->addGroupRule( 'scengroup', 'You have selected an invalid scenario!', 'ok_values' ) ; ... Did I miss something?Yes, you did. Look at the example in addGroupRule()'s docs, it shows how to add a complex group rule. http://pear.php.net/manual/en/package.html.html-quickform.html-quickform.addgrouprule.php