Yone Posted December 1, 2011 Report Share Posted December 1, 2011 I'm using php to connect to my MySQL database, and I need to know what the address of the database server is. With 1&1 I had: $server = "db1437.perfora.net"; in my php code. So, please, what is the equivalent $server for MDDHosting? Quote Link to comment Share on other sites More sharing options...
kuemerle5 Posted December 1, 2011 Report Share Posted December 1, 2011 Since the MySQL and web server run on the same machine, you can just put in "localhost" for the server address. Quote Link to comment Share on other sites More sharing options...
Scott Posted December 1, 2011 Report Share Posted December 1, 2011 Point of interest for those who are interested, localhost is correct as well as 127.0.0.1 (the default loopback address for all servers). Your domain name or the servers host name can also be used, but is not recommended as it will cause issues if your account is ever moved to another server, or in the event of an unexpected DNS change. Quote Link to comment Share on other sites More sharing options...
Psionmark Posted December 13, 2011 Report Share Posted December 13, 2011 Point of interest for those who are interested, localhost is correct as well as 127.0.0.1 (the default loopback address for all servers). Your domain name or the servers host name can also be used, but is not recommended as it will cause issues if your account is ever moved to another server, or in the event of an unexpected DNS change. I'm trying out an external auto backup solution (backupmachine.com). This requires an IP Address. I've tried that associated with my site (173.248.188.177), along with the database credentials, but it always fails authentication. Any idea how I give it access? Regards, Mark Quote Link to comment Share on other sites More sharing options...
kuemerle5 Posted December 13, 2011 Report Share Posted December 13, 2011 There is an option in cPanel to allow external hosts to connect to your MySQL server. Click the link for "Remote MySQL" and add the hostname or IP address of the computer that's going to be performing your backups. Quote Link to comment Share on other sites More sharing options...
Psionmark Posted December 13, 2011 Report Share Posted December 13, 2011 There is an option in cPanel to allow external hosts to connect to your MySQL server. Click the link for "Remote MySQL" and add the hostname or IP address of the computer that's going to be performing your backups. That did the trick Thanks very much for the quick reply. Mark Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.