title: Connect to Remote AWS MySQL from GoDaddy via PHP
body: <p>I'm having an issue connecting to a remote MySQL server that is hosted by Amazon Web Services. I can connect to this MySQL server from virtually any other computer, but for some reason I cannot get it to be pulled into my PHP that is hosted on GoDaddy.</p>
  
  <p>Here is the PHP code:</p>
  
  <pre><code>$cxn = mysql_connect($host,$user,$passwd,$dbname)
           or die("Query died: Cannot connect.");
  </code></pre>
  
  <p>I've added the host name for the MySQL server into GoDaddy's CPANEL > Remote MySQL Access Hosts. I know that the variables are correct, because I've tested this on another server and everything works fine.</p>
  
  <p>I've been on the phone with GoDaddy twice now, and all they've said is to try asking a forum (apart from adding the MySQL host to the Remote Access Hosts page).</p>
  
  <p>I've checked the security group for the AWS MySQL and made sure that it is open to the GoDaddy's hosted IP address...</p>
  
  <p>I'm just not sure what else to do! Why isn't this working on GoDaddy's server when it was working just fine on another??</p>
  
  <p>MySQL v5.6 --> on AWS
  PHP v5.4 --> on GoDaddy</p>