I have the following sitution...
MySQL version 3.23.47
PHP version 4.3.2
Redhat Linux version 7.1
Apache version 1.3.29
I have a MySQL user called 'user' that is set up with full rights for
localhost, 127.0.0.1, and the external IP address.
I can connect to the database using all three users from the command line...
../mysql --user=user --password=password --host=###.###.##.###
../mysql --user=user --password=password --host=127.0.0.1
../mysql --user=user --password=password --host=localhost
But in my php script running on the server, I can only connect using the
hostname localhost...
$DBConnection = mysql_connect("localhost","user","password");
the IP addresses don't work...
$DBConnection = mysql_connect("###.###.##.###","user","password");
$DBConnection = mysql_connect("127.0.0.1","user","password");
these give me the following error:
Warning: mysql_connect(): Can't connect to MySQL server on 'domain.com'
(111)
Is there anyone that's seen this and can point me in the right direction?
Thanks.