日期:2014-05-16 浏览次数:20512 次
PHP 连接mysql数据库
<?php $dbhost = 'localhost:3306'; $dbuser = 'root'; $dbpass = 'root'; $conn = mysql_connect($dbhost, $dbuser, $dbpass); if(! $conn ) { echo 'Connect failure'; } echo 'Connected successfully'; mysql_close(); ?>?