07-19-2011, 04:35 PM
When using MySQL, wouldn't this create multi-databases?
One every time the page is loaded?
Code:
<?php
$con = mysql_connect("localhost","peter","abc123");
if (!$con)
{
die(mysql_error());
}
if (mysql_query("CREATE DATABASE my_db",$con))
{
echo "Database created";
}
else
{
echo mysql_error();
}
mysql_close($con);
?>
One every time the page is loaded?