Guest User

Untitled

a guest
Jul 28th, 2018
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. if(isset($_GET['id']))
  2. {
  3. $id = $_GET['id'];
  4. $server = "localhost";
  5. $username = "greenfrog";
  6. $password = "test";
  7. $database = "test";
  8.  
  9. $con = mysql_connect($server, $username, $password);
  10. if (!$con)
  11. {
  12. die('Could not connect: ' . mysql_error());
  13. }
  14.  
  15. mysql_select_db($database, $con);
  16.  
  17. $result = mysql_query("SELECT newsletterId, title, body, date, isSent FROM newsletter WHERE newsletterId =" . $id);
  18. }
Add Comment
Please, Sign In to add comment