BeamNG_IRC

Untitled

Aug 17th, 2015
242
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. $con = mysqli_connect($hostname, $username, $password, $database);
  2. // Check connection
  3. if (mysqli_connect_errno()) {
  4. echo "Failed to connect to MySQL: " . mysqli_connect_error();
  5. mysqli_close($con);
  6. }
  7. $result = mysqli_query($con,"SELECT * FROM members WHERE username = '$username_confirm'");
  8. while($row = mysqli_fetch_array($result)) {
  9. $id = $row['id'];
  10. $pass = $row['password'];
  11. if ($password_confirm == $pass) {
  12. $confirm = 1;
  13. }
  14. }
  15. mysqli_close($con);
Advertisement
Add Comment
Please, Sign In to add comment