I'm having trouble connection to the database
Here is the code I am using
$con = mysql_connect('host', 'user', 'pass');
mysql_select_db('database_name', $con);
And here is the results I get
Warning: mysql_connect() [function.mysql-connect]: Lost connection to MySQL server at 'reading initial communication packet', system error: 111 in /home/heartbeat_db/heartbeatsmart.com/php/config/dbconnect.php on line 2
Warning: mysql_select_db() expects parameter 2 to be resource, boolean given in /home/heartbeat_db/heartbeatsmart.com/php/config/dbconnect.php on line 3
Warning: mysql_connect() [function.mysql-connect]: Lost connection to MySQL server at 'reading initial communication packet', system error: 111 in /home/heartbeat_db/heartbeatsmart.com/php/config/dbconnect.php on line 2
Warning: mysql_select_db() expects parameter 2 to be resource, boolean given in /home/heartbeat_db/heartbeatsmart.com/php/config/dbconnect.php on line 3
mysql_*functions in new code. They are no longer maintained and are officially deprecated. Learn about prepared statements instead, and use PDO or MySQLi - this article will help you decide which. If you choose PDO, here is a good tutorial. - cryptic ツ