0

Pretty much self explanatory...

But for some reason I'm getting a timeout...

Do I need to modify something at my cPanel or php.ini or httpd.conf on my Shared hosting server ?

I'm using XAMPP on my host and this is how I try to connect to my domain database :

$mysqli = mysqli_connect (
$mySharedHostingIP,
$mySharedHostingUserName,
$mySharedHostingPassword,
$mySharedHostingDB
);

Thanks for help!

Steve von Johnson
  • 121
  • 1
  • 1
  • 11
  • Default settings prevent connecting from external servers. Are you sure your provides enables that? – FrEaKmAn Jan 01 '15 at 16:28
  • 1
    possible duplicate http://stackoverflow.com/questions/8380797/enable-remote-mysql-connection-error-1045-28000-access-denied-for-user-root – FrEaKmAn Jan 01 '15 at 16:29
  • @FrEaKmAn This is exactly what I asked (if I need to modify something at my cPanel/php.ini/httpd.conf) and how do I modify. (no duplicate no worries I already saw that before I post)... – Steve von Johnson Jan 01 '15 at 16:33
  • If you are getting a timeout, that sounds suspiciously like the host simply doesn't accept inbound MySQL connections and firewalls them off. You should contact your host's support to see if they allow this behavior. – Michael Berkowski Jan 01 '15 at 16:34
  • If they do, it is likely then that you'll need to `GRANT` permissions to your db users to access from remote hosts, since MySQL establishes permissions by user, host, and password as 3 separate components. http://stackoverflow.com/questions/6239131/how-to-grant-remote-access-permissions-to-mysql-server-for-user – Michael Berkowski Jan 01 '15 at 16:35
  • `Do I need to modify something at my cPanel or php.ini or httpd.conf` ... that's probably the wrong direction to look. If you are getting a timeout *connecting to the database*, the place to look is the database, not the web server, and the database's firewall or whoever administers it (which might be you, via some kind of admin interface, but the lack of detail in the question makes it difficult to speculate what your next move should be). – Michael - sqlbot Jan 01 '15 at 23:22

0 Answers0