![]() |
I post data via AJAX on the server i get it like
[ name => '' sex=> '' ] My validation 'name' => [ 'label' => ' ', 'rules' => 'required' ], 'sex' => [ 'label' => ' ', 'rules' => 'in_list[male,female]', ], But when i load $this->validator->getErrors(); On"sex" field i got error "this field must be in list", but "sex" field is not required, why is happening? I need next actions when field is filled check in list, when field is empty dont check |
Messages In This Thread |
Validation Form - by motoroller - 11-19-2022, 11:50 AM
RE: Validation Form - by motoroller - 11-19-2022, 01:02 PM
|