Re: Connect Problem
| From: | Liam MacKenzie | Date: | Wed, 08 May 2002 04:42:01 +0000 |
| Subject: | Re: Connect Problem | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-96756@lists.php.net to get a copy of this message | ||
Try this...
$mysql_access = mysql_connect("localhost", "root", "yourpass");
if (!$mysql_access) { echo("ERROR: " . mysql_error() . "\n"); }
----- Original Message -----
From: "Jeremy" <wombat@bluetravel.com.au>
To: <php-general@lists.php.net>
Sent: Thursday, May 09, 2002 2:32 PM
Subject: [PHP] Connect Problem
Hey there,
I can't connect to mysql through a php web page, it isn't talking to it. And
also $PHP_SELF gives a permission error, access denied. Do I have
permissions set incorrectly?
This is my php,
<?php
$dbcnx = @mysql_connect("host", "user", "password");
if (!$dbcnx) {
echo ("blah");
exit();
}
?>
I get no errors, just no response so it obviously no connecting. Changing
user names or passwords produce the same result. I can connect with a shell
in the root mysql dir.
lost..
Jeremy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php