Hello,
Worked on PDO everything as far as i see is correct why i am getting an error
) Fatal error: Call to undefined method mysqli::insert_id()
$result = "INSERT INTO users(unique_id, firstname, lastname, email, username, encrypted_password, salt, created_at) VALUES('$uuid', '$fname', '$lname', '$email', '$uname', '$encrypted_password', '$salt', NOW())";
$connection->query($result);
// check for successful store
if ($result) {
// get user details
$uid = $connection->insert_id(); // last inserted id
$result1 = "SELECT * FROM users WHERE uid = $uid";
//$connection->query($result1);
// return user details
return $connection->fetch_array($result1);
} else {
return false;
}