title: Why can I connect to my hosted website database using localhost?
body: <p>This might be a stupid question but why am i using local host if my site is being hosted with rackspace?</p>
  
  <pre><code>$db_host = "localhost";
  $db_username = "*****";
  $db_pass = "********";
  $db_name = "lds";
  
  
  $link = mysql_connect('localhost','*****','*********');
      if (!$link) {
          die('Could not connect: ' . mysql_error());
      }
  echo 'Connected successfully';
  mysql_close($link);
  </code></pre>
  
  <p>It appears to be getting a connection because I'm successfully echoing 'Connected successfully'.</p>
  
  <p>Maybe something is terribly wrong because i noticed when i took out localhost from both mysql_connect function and from the db_host variable... it still says connected successfully. </p>
  
  <p>Would that be because i've already wired the ftp connections up in my IDE?</p>
  
  <p>Any help would be greatly appreciated. Thanks in advance.</p>