Hi!
I have a big problem with my website. When I try to connect it to an external host, it gives me a strange error:
PHP Code:
Severity: error --> Exception: Call to a member function errorInfo() on bool /home/qtbflcqc/panel.unitchamp.ro/system/database/drivers/pdo/pdo_driver.php 295
Unable to connect to the database
When I try to connect to the database from my localhost, it works fine, without any problem.
So, when I try to place the website on my PC, and connect it to the external host, it works perfect , no problem, no errors, but when I try to connect to it from the website (which is hosted), it gives me that error.
I set the Remote Acces from the external host, so there should be no problems.
Here is my database.php
PHP Code:
$active_group = 'default';
$query_builder = TRUE;
$db['default'] = array(
'dsn' => 'mysql:host=188.x.x.x; dbname=name; charset=utf8;',
'hostname' => '188.x.x.x',
'username' => 'nameuser',
'password' => 'pass',
'database' => 'name',
'dbdriver' => 'pdo',
'dbprefix' => '',
'pconnect' => FALSE,
'db_debug' => FALSE,
'cache_on' => FALSE,
'cachedir' => 'application/cache/',
'char_set' => 'utf8',
'dbcollat' => 'utf8_general_ci',
'swap_pre' => '',
'encrypt' => FALSE,
'compress' => FALSE,
'stricton' => FALSE,
'failover' => array(),
'save_queries' => TRUE
);
Thans a lot!