title: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
body: <p>I just manually installed a new plugin on my WordPress site, created a table in MySQL for the plugin's entries, and when I try to open the page that uses the plugin, I receive this error:</p>
  
  <pre><code>DataTables warning (table id = 'to-do_list'): An error occurred while 
  connecting to the database 'wordpress_clouse'. The error reported by the 
  server was: SQLSTATE[HY000] [2002] Can't connect to local MySQL server 
  through socket '/var/lib/mysql/mysql.sock' (2)
  </code></pre>
  
  <p>This is the MySQL info listed in my config file (which I believe is correct):</p>
  
  <pre><code>"type" =&gt; "Mysql",
  "user" =&gt; "root",
  "pass" =&gt; "******",
  "host" =&gt; "localhost",
  "port" =&gt; "",
  "db"   =&gt; "******"
  </code></pre>
  
  <p>This is the main contents of the /etc/my.cnf file:</p>
  
  <pre><code># The following options will be passed to all MySQL clients
  [client]
  #port       = 3306
  socket      = /var/run/mysqld/mysqld.sock
  
  # The MySQL server
  [mysqld]
  #port       = 3306
  socket      = /var/run/mysqld/mysqld.sock
  log_error   = mysqld.err
  
  skip-networking
  </code></pre>
  
  <p>I've looked at answers to similar errors but none of the solutions worked for me. Any help would be appreciated.</p>