install/upgrade MDL-24840 prevent the messaging pop-up from appearing during install or upgrade

Thanks to Colin Chambers.
This commit is contained in:
Tim Hunt 2010-10-25 10:47:16 +00:00
parent a813a74843
commit 3ed3e8d412

View File

@ -111,6 +111,7 @@ $CFG->xmlstrictheaders = false;
if (!core_tables_exist()) {
$PAGE->set_pagelayout('maintenance');
define('MESSAGE_WINDOW', true);
// fake some settings
$CFG->docroot = 'http://docs.moodle.org';
@ -193,6 +194,7 @@ if (empty($CFG->version)) {
if ($version > $CFG->version) { // upgrade
$PAGE->set_pagelayout('maintenance');
define('MESSAGE_WINDOW', true);
$a->oldversion = "$CFG->release ($CFG->version)";
$a->newversion = "$release ($version)";
@ -276,6 +278,7 @@ if (moodle_needs_upgrading()) {
// means core upgrade or installation was not already done
if (!$confirmplugins) {
$PAGE->set_pagelayout('maintenance');
define('MESSAGE_WINDOW', true);
$strplugincheck = get_string('plugincheck');
$PAGE->navbar->add($strplugincheck);
$PAGE->set_title($strplugincheck);