codeigniter db last id
function add_post($post_data){
$this->db->insert('posts', $post_data);
$insert_id = $this->db->insert_id();
return $insert_id;
} $this->db->insert('posts', $post_data);
$insert_id = $this->db->insert_id();
return $insert_id; $db = db_connect();
$query = $db->query("SELECT * FROM users ORDER BY id DESC LIMIT 1");
$result = $query->getRow();
Also in PHP:
- PHP Warning: PHP Startup: Unable to load dynamic library 'openssl' window
- check datatype php
- date("n", $time)
- Geoip php
- check if key is already exist in an associative array php
- How do I get a YouTube video thumbnail from the YouTube API?
- db seed for specific table laravel
- STR::unique laravel
- check laravel version
- @ development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --config=node_modules/laravel-mix/setup/webpack.config.js`
- display messege on specific date and time in php
- autouseal using awskms in vault
- create symfony project
- Warning: mysqli_fetch_all() expects parameter 1 to be mysqli_result, bool given in C:\newxammp\htdocs\learn\index.php on line 11
- refresh php
- create new project in laravel 7
- convert to int php
- How to check duplicate data in PHP
- array find duplicates php
- collection methods laravel
- date in pphp
- base64_decode image string php
- difference between GET, POST and REQUEST methods?
- encode decode in php