title: PHP Warning: mysql_query(): A link to the server could not be established
body: <p>I installed Hybrid plugin on my Wordpress page and on activate this plugin I am getting this error:</p>
  
  <pre><code>PHP Warning: mysql_query(): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /www/wp-content/plugins/hybridconnect/tableInstall.php on line 2056
  </code></pre>
  
  <p>So I checked this file (tableInstall.php) and there is function:</p>
  
  <pre><code>function check_column_exists($db, $column) {
      $exists = false;
      if ($columns = mysql_query("show columns from $db")) {
          while ($c = mysql_fetch_assoc($columns)) {
              if ($c['Field'] == $column) {
                  $exists = true;
                  break;
              }
          }
      } else {
          echo (mysql_error());
      }
      return($exists);
  }
  </code></pre>
  
  <p>So this line will cause error:</p>
  
  <pre><code>$columns = mysql_query("show columns from $db")
  </code></pre>
  
  <p>And from:</p>
  
  <pre><code>echo (mysql_error());
  </code></pre>
  
  <p>I am getting this:</p>
  
  <pre><code>Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock'
  </code></pre>
  
  <p>So this was worked on my old server and after I moved my site to another server I am getting this error.</p>
  
  <p>What does this mean and how I can fix it?</p>