$db = new PDODb('host', 'username', 'password', 'databaseName');
It maps the parameters to the incorrect parts, the type is missing.
Which means it maps host to type
This works
$db = new PDODb('mysql', DBHost, DBUser, DBPassword, DBName);
This does
$db = new PDODb(['type' => 'mysql',
'host' => DBHost,
'username' => DBUser,
'password' => DBPassword,
'dbname'=> DBName,
'port' => 3306,
'prefix' => '',
'charset' => 'utf8']);
This does not work
$db = new PDODb('host', 'username', 'password', 'databaseName'); It maps the parameters to the incorrect parts, the type is missing. Which means it maps host to type
This works $db = new PDODb('mysql', DBHost, DBUser, DBPassword, DBName);
This does $db = new PDODb(['type' => 'mysql', 'host' => DBHost, 'username' => DBUser, 'password' => DBPassword, 'dbname'=> DBName, 'port' => 3306, 'prefix' => '', 'charset' => 'utf8']);