Skip to content

Instantly share code, notes, and snippets.

@abdullahbutt
Created October 21, 2013 07:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abdullahbutt/7079845 to your computer and use it in GitHub Desktop.
Save abdullahbutt/7079845 to your computer and use it in GitHub Desktop.
PHP mysql_connect() Function
<?php
$con = mysql_connect("localhost","mysql_user","mysql_pwd");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
// some code
mysql_close($con);
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment