Connection in php


$mysql_hostname = "locahost";
$mysql_user = "root";
$mysql_password = "";
$mysql_database = "table name[userdetails]";
$con = mysql_connect($mysql_hostname, $mysql_user, $mysql_password)
or die("Opps some thing went wrong or not connect to databse");
mysql_select_db("database name", $con) or die("Opps some thing or not selected db ....");
?>

0 comments:

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Design by NDR Group | Bloggerized by Er. Nelson Desai | Love U My Friends