title: Cannot log in to the MySQL server (PhpMyAdmin)
body: <p><strong>I installed both MySQL and PhpMyAdmin via Homebrew.</strong> I get the following error when I try to login with root and its password:</p>
  
  <pre><code>Cannot log in to the MySQL server
  </code></pre>
  
  <p>I can log in to MySQL via the terminal with:</p>
  
  <pre><code>mysql -u root -p
  </code></pre>
  
  <p><strong>PhpMyAdmin config:</strong></p>
  
  <pre><code>/* Authentication type */
  $cfg['Servers'][$i]['auth_type'] = 'cookie';
  /* Server parameters */
  $cfg['Servers'][$i]['host'] = '127.0.0.1';
  $cfg['Servers'][$i]['connect_type'] = 'tcp';
  $cfg['Servers'][$i]['user'] = 'root';
  $cfg['Servers'][$i]['password'] = 'pass';
  $cfg['Servers'][$i]['compress'] = false;
  $cfg['Servers'][$i]['AllowNoPassword'] = false;
  </code></pre>
  
  <p>I'm running this on <strong>apache</strong>. I tried all the solutions on stackoverflow but they don't seem to work. Can anyone help me?</p>