Skip to content

Instantly share code, notes, and snippets.

@ricardofiorani
Created March 10, 2014 12:40
Show Gist options
  • Save ricardofiorani/9464290 to your computer and use it in GitHub Desktop.
Save ricardofiorani/9464290 to your computer and use it in GitHub Desktop.
How to add a custom validator ?
/*@var $this myCustomInputFilter extends InputFilter*/
/* Cnpj */
$this->add([
'type' => 'Zend\InputFilter\InputFilter',
'vCnpj' => [
'name' => 'vCnpj',
'required' => true,
],
]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment