title: mysql_connect CHANGE TO mysqli
body: <p>I have some existing PHP code that is now throwing a fatal error since we migrated to PHP 7.0.  Using this <a href="https://stackoverflow.com/questions/10615436/fatal-error-call-to-undefined-function-mysql-connect">Stackoverflow Question</a> I've altered this line:</p>
  
  <pre><code>$link = mysql_connect($host.':'.$port, $user, $pass) or die("Can not connect." . mysql_error());
  </code></pre>
  
  <p>to this:</p>
  
  <pre><code>$link = new mysqli($host.':'.$port, $user, $pass);
  </code></pre>
  
  <p>I am now throwing this error which I guess is some progress.  The syntax seems fine?  What am I missing?</p>
  
  <pre><code>Warning: mysqli::__construct(): (HY000/2002): Connection timed out
  </code></pre>