1
0
mirror of https://github.com/moodle/moodle.git synced 2025-04-25 10:26:17 +02:00

Use SITEID instead of hardcoded value.

SITEID could be != 1 in older installations.
This commit is contained in:
paca70 2005-05-11 08:57:14 +00:00
parent 1d9498e455
commit eeefd0b0df
2 changed files with 2 additions and 2 deletions

@ -17,7 +17,7 @@
error("Could not create site folder. The site administrator needs to fix the file permissions");
}
$filename = $CFG->dataroot.'/1/maintenance.html';
$filename = $CFG->dataroot.'/'.SITEID.'/maintenance.html';
if ($form = data_submitted()) {
if (confirm_sesskey()) {

@ -1280,7 +1280,7 @@ function require_login($courseid=0, $autologinguest=true, $cm=null) {
// If the site is currently under maintenance, then print a message
if (!isadmin()) {
if (file_exists($CFG->dataroot.'/1/maintenance.html')) {
if (file_exists($CFG->dataroot.'/'.SITEID.'/maintenance.html')) {
print_maintenance_message();
exit;
}