Question about MySQL connection failures
| From: | Paul Menard | Date: | Wed, 09 Apr 2003 13:38:17 +0000 |
| Subject: | Question about MySQL connection failures | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-19371@lists.php.net to get a copy of this message | ||
Greeting all,
On occasion my PHP script/Web page reports that the
attemped connection to the database failed. Here is
the exact code from the top of my script.
$mysql_conn = mysql_connect($dbhost, $dbuser, $dbpass)
or die("MySQL Connection failed!!!");
My question is in regards to the die().
Is there a better way to determine what the MySQL
error was or why the connection failed?
Paul
__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - File online, calculators, forms, and more
http://tax.yahoo.com