Welcome Guest, Not a member yet? Register   Sign In
validation for values in array
#1

Hi, 

I am building API with CI v3. 
REST library automatically parses $_POST variable and puts contents in another variable.

I want form_validation library to validate the data I provide not posted ones.
Reply
#2

Easy. For example:

PHP Code:
$data = array(
 
       'username' => 'johndoe',
 
       'password' => 'mypassword',
 
       'passconf' => 'mypassword'
);

$this->form_validation->set_data($data); 

Documented here
Reply
#3

thank you very much!
Reply




Theme © iAndrew 2016 - Forum software by © MyBB