Welcome Guest, Not a member yet? Register   Sign In
Active Record Question
#1

[eluser]Mike L[/eluser]
Okay, I have a user table in my database and I have the username field set to unique so that two people can not have the same username. I would like to test whether or not the a user gets inserted into the database. I tried the code below, it does not work.

Code:
$data = array(
    //data etc..
);

if($this->db->insert('user', $data))
{
    return TRUE;
}
else
{
    return FALSE;
}

Thanks in advance.
#2

[eluser]Mike L[/eluser]
I found a solution, feel free to delete this topic.




Theme © iAndrew 2016 - Forum software by © MyBB