Code: Select all
$dbuk = mysql_connect("localhost","root","")or die ('Could not connect to site1.co.uk');
$db2uk = mysql_connect("localhost","root","")or die ('Could not connect to site2.co.uk');
mysql_select_db('site1', $dbuk) or die ('Could not connect to site1.co.uk Database');
mysql_select_db('site2', $db2uk)or die ('Could not connect to site2.co.uk Database')or die(mysql_error());For some reason, when we run queries locally, it only checks on the first database, doesn't query the second one at all.
It's as though, the queries to check the first and second DB, are both done on the first one only.
Run in a LIVE environment, they work just fine (obviously tho with username and passwords and "localhost" being an IP address.
Is the problem just that I have to use usernames on both internal DBs??