From 01b05bc715296446e7adfd301979d42d0b4cdaf2 Mon Sep 17 00:00:00 2001 From: Ruan Date: Sat, 6 Jun 2015 08:59:22 +0200 Subject: [PATCH] Allow driver to be changed in settings.php --- includes/settings.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/settings.php b/includes/settings.php index b3b1517..51b2896 100644 --- a/includes/settings.php +++ b/includes/settings.php @@ -22,17 +22,18 @@ $limit_per_page = 20; // If you set a table prefix in config.yml, put it here too $table_prefix = ""; +$driver = 'mysql'; /*****************************************************************************/ function litebans_connect() { // imported - global $dbhost, $username, $password, $database, $table_prefix, $show_inactive_bans; + global $dbhost, $username, $password, $database, $table_prefix, $show_inactive_bans, $driver; // exported global $conn, $active_query; global $table_bans, $table_mutes, $table_warnings, $table_history; - $dsn = 'mysql:dbname=' . $database . ';host=' . $dbhost . ';charset=utf8'; + $dsn = $driver . ':dbname=' . $database . ';host=' . $dbhost . ';charset=utf8'; try { $conn = new PDO($dsn, $username, $password);