Zend_Validate and Contextual Validation
ZendEditor |
Comments Off | December 31st, 2008
Jeremy Kendall has suggested a method for performing conditional context-based validation using Zend_Validate. His method, which involves using a custom validator that tests the context, allows you to “check the value of a parent field to see if a child field should be required.”
If context-based validation is something you’ve been scratching your head over, Jeremy’s post (which also contains a few other tricks) should give you some food for thought. Take a look, and add your own custom validator ideas to the comments thread!

