title: What is PDO database configuration in CodeIgniter?
body: <p>In <code>application/config/database.php</code>for setting up a optimal database configuration should set the <code>$db['default']['hostname'] = '';</code> to <code>'localhost'</code> by use of mysql driver.</p>
  
  <p>But when we use PDO driver for this configuration and localhost for the host name we see ERROR. What is PDO database hostname configuration in CodeIgniter with PDO driver shown below and what should place instead of question mark?</p>
  
  <pre><code>$db['default']['hostname'] = '?????';
  $db['default']['username'] = 'root';
  $db['default']['password'] = '';
  $db['default']['database'] = 'XXX';
  $db['default']['dbdriver'] = 'PDO';
  </code></pre>