I try to connect to a mysql database via PHPs mysqli.
define('DB_SERVER', '127.0.0.3');
define('DB_USERNAME', '570466');
define('DB_PASSWORD', 'pssst!');
define('DB_NAME', 'db570466');
/* Attempt to connect to MySQL database */
$mysqli = new mysqli(DB_SERVER, DB_USERNAME, DB_PASSWORD, DB_NAME);
And get the following error:
Warning: mysqli::mysqli(): (HY000/1045): Access denied for user '570466'@'localhost' (using password: YES) in /.../config.php on line 16
The strange thing is, that Access is denied for my user @localhost
, but I don't connect to localhost. According to my hoster (domainFactory), I can also connect to the DB via mysql5.my-domain.tld
, but that gives me the same output.
What am I missing?