scorm: MDL-16185 display warning when zlib_compression on - causes errors with certain browsers.

This commit is contained in:
danmarsden
2008-11-10 07:43:24 +00:00
parent 01bb194a4e
commit edf13ee87a
2 changed files with 5 additions and 0 deletions
+1
View File
@@ -188,4 +188,5 @@ $string['noattemptsallowed'] = "Number of attempts allowed";
$string['noattemptsmade'] = "Number of attempts you have made";
$string['gradeforattempt'] = "Grade for attempt";
$string['exceededmaxattempts'] = "You have reached the maximum number of attempts.";
$string['zlibwarning'] ='Warning: PHP Zlib compression has been enabled on this site, some users may experience issues loading SCORM objects in certain web browsers.';
?>
+4
View File
@@ -23,6 +23,10 @@ class mod_scorm_mod_form extends moodleform_mod {
if (!$CFG->slasharguments) {
$mform->addElement('static', '', '',notify(get_string('slashargs', 'scorm'), 'notifyproblem', 'center', true));
}
$zlib = ini_get('zlib.output_compression'); //check for zlib compression - if used, throw error because of IE bug. - SEE MDL-16185
if (isset($zlib) && $zlib) {
$mform->addElement('static', '', '',notify(get_string('zlibwarning', 'scorm'), 'notifyproblem', 'center', true));
}
//-------------------------------------------------------------------------------
$mform->addElement('header', 'general', get_string('general', 'form'));