From 71eee5f2160f2f522b13f070894a522bc5cafde6 Mon Sep 17 00:00:00 2001 From: skodak Date: Tue, 30 Jan 2007 09:33:11 +0000 Subject: [PATCH] MDL-8343 reorganize frontpage settings in admintree - fixed installation bug and warnings --- admin/index.php | 2 +- admin/settings/frontpage.php | 4 ++++ theme/standardwhite/footer.html | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/admin/index.php b/admin/index.php index 56a9d36afe..d47f9e93bf 100644 --- a/admin/index.php +++ b/admin/index.php @@ -498,7 +498,7 @@ /// check that site is properly customized if (empty($site->shortname) or empty($site->shortname)) { - redirect('settings.php?section=frontpage&return=site'); + redirect('settings.php?section=frontpagesettings&return=site'); } /// Check if we are returning from moodle.org registration and if so, we mark that fact to remove reminders diff --git a/admin/settings/frontpage.php b/admin/settings/frontpage.php index db77184861..576d9c6efa 100644 --- a/admin/settings/frontpage.php +++ b/admin/settings/frontpage.php @@ -2,6 +2,8 @@ // This file defines everything related to frontpage +if (get_site()) { //do not use during installation + $frontpagecontext = get_context_instance(CONTEXT_COURSE, SITEID); // "frontpage" settingpage @@ -35,4 +37,6 @@ $ADMIN->add('frontpage', new admin_externalpage('frontpagebackup', get_string('f $ADMIN->add('frontpage', new admin_externalpage('frontpagerestore', get_string('frontpagerestore', 'admin'), $CFG->wwwroot.'/files/index.php?id='.SITEID.'&wdir=/backupdata', 'moodle/site:restore', false, $frontpagecontext)); $ADMIN->add('frontpage', new admin_externalpage('sitefiles', get_string('sitefiles'), $CFG->wwwroot . '/files/index.php?id=' . SITEID, 'moodle/course:managefiles', false, $frontpagecontext)); + +} ?> \ No newline at end of file diff --git a/theme/standardwhite/footer.html b/theme/standardwhite/footer.html index 5a63efe65b..5c790f4420 100644 --- a/theme/standardwhite/footer.html +++ b/theme/standardwhite/footer.html @@ -15,7 +15,7 @@