i am converting my old mysql to mysqli but ran into this problem mysqli result does not work.looked on the internet and i founded out that it function had been change,for mysqli result is there a equivalent out here?
thank
here my error
Fatal error: Call to undefined function mysqli_result() in C:\xampp\htdocs\bear_mysqli\functions\users.php on line 153
function user_exists($con,$username)
{
$username = sanitize($con,$username);
$query = mysqli_query($con,"SELECT COUNT(`user_id`)FROM `users` WHERE `username` = '$username'");
return (mysqli_result ($query, 0)== 1) ? true : false;
}
No comments:
Post a Comment