Hi,
I have a requirement to allow remote access to my mysql database.
I\'ve read a million threads on this subject and none of them seem to give clear instructions on how to do this.
I tried the following code.
where $db_hostname is the ip address of the server.
$db_hostname= xxx.xxx.xxx.xxx
$db_username="XXXXX";
$db_password="YYYYYY";
if(!mysql_connect("$db_hostname","$db_username","$db_password"))
{
echo "SQL_ERROR: Cannot connect to Database: $db_name<br>"; exit();
}
else
{
echo "Connection successful";
}
This produced the following set of errors.
If I use localhost as the db_hostname I connect without any problems. What do I have to do to allow a remote connection to the database?
Is this a coding issue or is there a setting on the server that needs to be changed?
All help and suggestion greatfully received!
Rob