Set default charset to utf-8.

This commit is contained in:
Thomas Tanghus 2012-06-16 16:58:55 +02:00
parent 31ec93bd00
commit 709dbd82a6
1 changed files with 1 additions and 1 deletions

View File

@ -120,7 +120,7 @@ class OC_DB {
}else{
$dsn='mysql:dbname='.$name.';host='.$host;
}
$opts[PDO::MYSQL_ATTR_INIT_COMMAND] = "SET NAMES 'UTF8'";
$opts[PDO::MYSQL_ATTR_INIT_COMMAND] = "SET NAMES 'UTF8'; SET CHARACTER SET 'UTF8';";
break;
case 'pgsql':
if($port){