连接数据库

<?php
$con = mysql_connect("localhost","root","root");
if (!$con) {
die('Could not connect: ' . mysql_error());
}
else
{
echo "ok!";
}
// some code mysql_close($con);
?>
05-11 21:47