mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/11547] Set MySQL charset to UTF8 in database_test_connection_manager.
PHPBB3-11547
This commit is contained in:
parent
f2fd0031f4
commit
225aba976e
1 changed files with 8 additions and 0 deletions
|
@ -142,6 +142,14 @@ class phpbb_database_test_connection_manager
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
|
$this->pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
|
||||||
|
|
||||||
|
switch ($this->config['dbms'])
|
||||||
|
{
|
||||||
|
case 'mysql':
|
||||||
|
case 'mysqli':
|
||||||
|
$this->pdo->exec('SET NAMES utf8');
|
||||||
|
default:
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Reference in a new issue