Hi, I have problem.
I get only callback validation.
Why?
I get only callback validation.
Why?
PHP Code:
$this->form_validation->set_rules(
'user_passcurr',
'current password',
'trim|required|min_length[6]|max_length[32]|check_passcurr|strip_tags',
[
'required' => 'error0',
'min_length' => 'error1',
'max_length' => 'error2',
]
);
PHP Code:
public function check_passcurr(string $str)
{
if ($this->user_model->passcurr_verify($this->session->user_id, $str)) {
return TRUE;
} else {
$this->form_validation->set_message('check_passcurr', 'Error {field}');
return FALSE;
}
}