Disable notInArray Validator Zend Framework 2

后端 未结 5 2395
醉梦人生
醉梦人生 2021-02-20 12:36

Is there a way to disable notInArray Validator in Zend Framework 2. All the info on the internet shows how to disable the notInArray Validator in Zend Framework 1, for example i

5条回答
  •  抹茶落季
    2021-02-20 13:03

    Since version 2.2, Zend Framework provide the ability to disable inArray validator calling:

    $element->setDisableInArrayValidator(false);
    

    or passing option to an element:

    'disable_inarray_validator' => false
    

提交回复
热议问题