From d186405c0090772d1c26788dad9ea973f0421390 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak <alec@alec.pl> Date: Sat, 08 Jun 2013 14:14:33 -0400 Subject: [PATCH] Simplified db connection initialisation code --- program/lib/Roundcube/rcube_db_pgsql.php | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/program/lib/Roundcube/rcube_db_pgsql.php b/program/lib/Roundcube/rcube_db_pgsql.php index 984dd57..d72c9d6 100644 --- a/program/lib/Roundcube/rcube_db_pgsql.php +++ b/program/lib/Roundcube/rcube_db_pgsql.php @@ -29,6 +29,17 @@ public $db_provider = 'postgres'; /** + * Driver-specific configuration of database connection + * + * @param array $dsn DSN for DB connections + * @param PDO $dbh Connection handler + */ + protected function conn_configure($dsn, $dbh) + { + $this->query("SET NAMES 'utf8'"); + } + + /** * Get last inserted record ID * * @param string $table Table name (to find the incremented sequence) -- Gitblit v1.9.1