From efcb166c2d80242dbfc7b2b395773f4337b0ce3f Mon Sep 17 00:00:00 2001 From: Michael Date: Tue, 25 Apr 2017 06:10:14 +0000 Subject: [PATCH] Added check for MySQL driver for PDO. --- mod/install.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mod/install.php b/mod/install.php index 64defb19e8..d1d2fd0779 100755 --- a/mod/install.php +++ b/mod/install.php @@ -415,6 +415,10 @@ function check_funcs(&$checks) { $ck_funcs[3]['status'] = false; $ck_funcs[3]['help'] = t('Error: PDO or MySQLi PHP module required but not installed.'); } + if (!function_exists('mysqli_connect') && class_exists('pdo') && !in_array('mysql', PDO::getAvailableDrivers())) { + $ck_funcs[3]['status'] = false; + $ck_funcs[3]['help'] = t('Error: The MySQL driver for PDO is not installed.'); + } if (! function_exists('mb_strlen')) { $ck_funcs[4]['status'] = false; $ck_funcs[4]['help'] = t('Error: mb_string PHP module required but not installed.'); -- 2.39.5