How to get last insert id in Codeigniter
$this->db->insert(‘users’, $data); # where $data is an array
$insert_id = $this->db->insert_id(); # insert_id() fucntion returns last insert id
return $insert_id;
$this->db->insert(‘users’, $data); # where $data is an array
$insert_id = $this->db->insert_id(); # insert_id() fucntion returns last insert id
return $insert_id;
"if ( $this->input->is_ajax_request() ) { // your code here... }" read more
If you are a victim of Browser Modifier Virus ( malware ) Browser... read more
With our data increasingly moving to the cloud, chances are that whenever... read more
After a lots of headache, I find the solutions. I am using... read more
Major Differences are: Git and Mercurial are the two most popular Distributed Version... read more
Simple structure to pin the flow to developers mind for project IS ... read more
The regex caused the error during validation check on Alphaspace Rules regular... read more
In simple words, class is a user defined datatype. Which have its... read more
The character set named utf8 uses a maximum of three bytes per... read more
Leave a Reply