Go to website
Guides on cPanel features.
How to connect to a MySQL database using PHP
The hostname to use when connecting to one of your cPanel MySQL databases from a web script running within the same cPanel account is localhost. As a quick guide, you can use the following PHP code to make a connection.
How to connect to a MySQL database from an external host
MySQL server runs on each local hosting server on TCP Port 3306 (the standard port for MySQL). When your web scripts connect to MySQL they can do so using simply localhost as the server name. However, you can also connect to your databases from an external host, such as your home PC, office, or another web server. Preparing to connect Before getting started you will need the IP address of the host you are connecting from, this can be done by browsing to https://viewmyip.co.uk on the devi