Hello,

Was wondering if anyone has come across this problem previously.
I am using the preconfigured form spec to create form using the
Zend\Form\Factory, I am also injecting the FormElementManager into the
factory so it can find my custom elements etc.

My question is:

Even tho any custom validators are registered with the form, they do not
trigger isValid() method. Is there anything I need to do to get the
isValid() triggered with creating the form with factory.


My source looks like following:

<?php
$spec = [
'hydrator' => '...',
'fieldset' => [
...,
...,
...,
],
'input_filter' => [
...,
....
....,
//contains my custom validator in here
],
];
$factory = new Factory();
$factory->setFormElementManager($formElementManager);
$form = $factory->createForm($spec);

But when I trigger:
$form->isValid()
It doesn't get to the isValid call in my custom validator.

Thank you,
Bikash

Reply via email to