diff options
-rw-r--r-- | lib/debug.lib.php | 10 | ||||
-rw-r--r-- | templates/show_test_table.inc.php | 19 |
2 files changed, 20 insertions, 9 deletions
diff --git a/lib/debug.lib.php b/lib/debug.lib.php index 7ce061f6..e254828a 100644 --- a/lib/debug.lib.php +++ b/lib/debug.lib.php @@ -26,6 +26,7 @@ function check_php() { check_php_hash() && check_php_hash_algo() && check_php_pdo() && + check_php_pdo_mysql() && check_php_session() && check_php_json() && check_php_safemode() @@ -60,10 +61,11 @@ function check_php_session() { } function check_php_pdo() { - if (class_exists('PDO') && in_array('mysql', PDO::getAvailableDrivers())) { - return true; - } - return false; + return class_exists('PDO'); +} + +function check_php_pdo_mysql() { + return class_exists('PDO') ? in_array('mysql', PDO::getAvailableDrivers()) : false; } /** diff --git a/templates/show_test_table.inc.php b/templates/show_test_table.inc.php index f48bc429..7816a41e 100644 --- a/templates/show_test_table.inc.php +++ b/templates/show_test_table.inc.php @@ -30,7 +30,7 @@ </td> </tr> <tr> - <td valign="top"><?php echo T_('Hash extension'); ?></td> + <td valign="top"><?php echo T_('PHP hash extension'); ?></td> <td valign="top"> <?php echo debug_result(check_php_hash()); ?> </td> @@ -39,7 +39,7 @@ </td> </tr> <tr> - <td valign="top"><?php echo T_('SHA256 Hash'); ?></td> + <td valign="top"><?php echo T_('SHA256'); ?></td> <td valign="top"> <?php echo debug_result(check_php_hash_algo()); ?> </td> @@ -48,12 +48,21 @@ </td> </tr> <tr> - <td valign="top"><?php echo T_('PHP PDO'); ?></td> + <td valign="top"><?php echo T_('PHP PDO extension'); ?></td> <td valign="top"> <?php echo debug_result(check_php_pdo()); ?> </td> <td> - <?php echo T_('This tests whether the PDO extension and the MySQL driver for PDO are installed. These are required by Ampache.'); ?> + <?php echo T_('This tests whether you have the PDO extension enabled. This extension is required by Ampache.'); ?> + </td> +</tr> +<tr> + <td valign="top"><?php echo T_('MySQL'); ?></td> + <td valign="top"> + <?php echo debug_result(check_php_pdo_mysql()); ?> + </td> + <td> + <?php echo T_('This tests whether the MySQL driver for PDO is enabled. This driver is required by Ampache.'); ?> </td> </tr> <tr> @@ -75,7 +84,7 @@ </td> </tr> <tr> - <td valign="top"><?php echo T_('JSON extension'); ?></td> + <td valign="top"><?php echo T_('PHP JSON extension'); ?></td> <td valign="top"> <?php echo debug_result(check_php_json()); ?> </td> |