utf-8
This commit is contained in:
parent
af80a4f0ec
commit
5dac5a6e19
2 changed files with 3 additions and 2 deletions
|
|
@ -26,6 +26,7 @@ class Database extends PDO
|
|||
if ($dsn['phptype'] == 'pgsql' || $dsn['phptype'] == 'mysql') {
|
||||
$port = (isset($dsn['port'])) ? "port={$dsn['port']};" : "";
|
||||
$connection = new Database("{$dsn['phptype']}:host={$dsn['hostspec']}; $port dbname={$dsn['database']}", $dsn['username'], $dsn['password']);
|
||||
$connection->query('SET client_encoding = "UTF-8"');
|
||||
}
|
||||
if ($dsn['phptype'] == 'sqlite') {
|
||||
$connection = new Database("{$dsn['phptype']}:{$dsn['database']}");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue