Advertisement
Guest User

Untitled

a guest
Sep 23rd, 2017
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.87 KB | None | 0 0
  1. <?php
  2. $host = "localhost";
  3. $db_username = "*****"; // Your database username
  4. $db_pass = "*****"; // the password to your username
  5. $db_name = "*****"; // the name of the database your 'users' table is in.
  6. $connection = mysql_connect("$host","$db_username","$db_pass") or die ("Couldn't connect to server.");
  7. $db = mysql_select_db("$db_name", $connection) or die("Couldn't select database.");
  8. error_reporting (E_ALL ^ E_NOTICE);
  9. $salt = "ZKd88lUhsk21"; // creates a salt value to better encrypt the users password
  10. $mysql = mysql_query("SELECT * FROM users WHERE username='".safe($_COOKIE['username'])."' AND id='".safe($_COOKIE['id'])."' AND password='".safe($_COOKIE['password'])."'");
  11. $row = mysql_fetch_array($mysql);
  12. $registration_date = $row['regdate'];
  13. $email = $row['email'];
  14. $website = $row['website'];
  15. $location = $row['location'];
  16. $show_email = $row['show_email'];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement