0

This is my code and its not giving me result. It is returning me false value while there is data with same credentials inside database. I tried everything but it is not working.

private function isUserExist($email_id, $user_id){

  $stmt = $this->conn->prepare("SELECT id FROM users WHERE `email_id` = ? AND `unique_user_id` = ?");
  $stmt->bindParam(1, $email_id);
  $stmt->bindParam(2, $user_id);
  $stmt->execute();
  return $stmt->fetch() > 0;
}
Dave
  • 5,108
  • 16
  • 30
  • 40

0 Answers0