MDL-55083 admin: provide friendly error in case phpxml is missing

This commit is contained in:
tunele 2016-07-01 12:43:20 +02:00
parent 5a1728df39
commit f029401b36

View File

@ -52,6 +52,12 @@ if (!function_exists('json_encode') || !function_exists('json_decode')) {
die();
}
// Make sure xml extension is available.
if (!extension_loaded('xml')) {
echo 'Moodle requires the xml PHP extension. Please install or enable the xml extension.';
die();
}
define('NO_OUTPUT_BUFFERING', true);
if (isset($_POST['upgradekey'])) {