Still not quite there. I believe I may be using Zend_Filter_Input incorrectly. I made the changes to my $_validators array as described and now it throws the following exception
Fatal error: Uncaught exception 'Zend_Loader_PluginLoader_Exception' with message 'Plugin by name 1 was not found in the registry.' ... Zend_Loader_PluginLoader->load('1') Just for reference, when I print out the $_validators array that's passed to my validation function, this is the result: Array ( [field1] => Array ( [0] => Array ( [validator] => 1 [breakChainOnFailure] => 1 [options] => Array ( [0] => /[^a-z'-]/i ) ) ) ) So it looks as if it's taking the 'true' in either the validator value or the breakchainonfailure value of the array and trying to load it. I've tried to script it in a few different ways and triple-checked that I have the $_validators array set up correctly (testing with only the single field) and get the same exception. Matthew Weier O'Phinney-3 wrote: > > -- benxmy <ben...@gmail.com> wrote > (on Monday, 02 February 2009, 01:58 PM -0800): > > You're creating the validators array incorrectly. I'm assuming from > your example that you're creating an array of field => validators arrays > that you use to create your elements. The problem with how you've done > it is that setValidators(), which is called when you pass validators via > the constructor, expects that each element in the array is either a > string or an array representing a single validator. Additionally, you > can sometimes run into issues with order of operators, so I typically > recommend using key/value pairs in each array defining a validator. > > Try the following: > > protected $_validators = array( > 'field1' => array( > array( > 'validator' => true, > 'breakChainOnFailure' => true, > 'options' => array('/[^a-z\' -]/i'), > ), > ), > ); > > -- View this message in context: http://www.nabble.com/getMessages%28%29-crashes-with-quotes%21-tp21793751p21817057.html Sent from the Zend Framework mailing list archive at Nabble.com.