I\'m trying to use the PDO MySQL driver in my CodeIgniter application. This is my database config:
$active_group = \'default\';
$active_record = TRUE;
$db[\
According to CodeIgniter's Database Configuration page,
For the PDO driver, you should change the 'hostname => 'localhost'
' to "'hostname' => mysql:host=localhost
" like below:
$db['default'] = array(
'dsn' => '',
'hostname' => 'mysql:host=localhost',
'username' => 'root',
'password' => '',
'database' => 'database_name',
'dbdriver' => 'pdo',
'dbprefix' => '',
'pconnect' => FALSE,
'db_debug' => (ENVIRONMENT !== 'production'),
.....
.....
);