Advertisement
Guest User

mysqli_num_rows() expects parameter 1 to be mysqli_result,

a guest
Oct 19th, 2016
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.31 KB | None | 0 0
  1. $conn=mysqli_connect('localhost',$username,$pass,$db);
  2.         $query="SELECT * FROM account WHERE username='$nim' and password='$pwd'";
  3.         $result = mysqli_query($conn,$query);
  4.         $count = mysqli_num_rows($result);
  5.         if ($count!=0){
  6.             return true;
  7.         } else {
  8.             die ('No such account found!');
  9.             return false;
  10.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement