diff --git a/theme/bootstrapbase/config.php b/theme/bootstrapbase/config.php index 4ca1d8376f9..bcf4697fdf2 100644 --- a/theme/bootstrapbase/config.php +++ b/theme/bootstrapbase/config.php @@ -126,12 +126,11 @@ $THEME->layouts = array( 'regions' => array() ), // Used during upgrade and install, and for the 'This site is undergoing maintenance' message. - // This must not have any blocks, and it is good idea if it does not have links to - // other places - for example there should not be a home link in the footer... + // This must not have any blocks, links, or API calls that would lead to database or cache interaction. + // Please be extremely careful if you are modifying this layout. 'maintenance' => array( - 'file' => 'columns1.php', + 'file' => 'maintenance.php', 'regions' => array(), - 'options' => array('nofooter'=>true, 'nonavbar'=>true, 'nocoursefooter'=>true, 'nocourseheader'=>true), ), // Should display the content and basic headers only. 'print' => array( diff --git a/theme/bootstrapbase/layout/maintenance.php b/theme/bootstrapbase/layout/maintenance.php new file mode 100644 index 00000000000..5b0b9f7ea1b --- /dev/null +++ b/theme/bootstrapbase/layout/maintenance.php @@ -0,0 +1,62 @@ +. + +/** + * This layout file is designed maintenance related tasks such as upgrade and installation of plugins. + * + * It's ultra important that this layout file makes no use of API's unless it absolutely needs to. + * Under no circumstances should it use API calls that result in database or cache interaction. + * + * If you are modifying this file please be extremely careful, one wrong API call and you could end up + * breaking installation or upgrade unwittingly. + */ + +echo $OUTPUT->doctype() ?> +htmlattributes(); ?>> + + <?php echo $OUTPUT->page_title(); ?> + + standard_head_html() ?> + + + +body_attributes(); ?>> + +standard_top_of_body_html() ?> + +
+ + + +
+
+ main_content(); ?> +
+
+ + + + standard_end_of_body_html() ?> + +
+ + diff --git a/theme/bootstrapbase/upgrade.txt b/theme/bootstrapbase/upgrade.txt index 942f514c098..ceb6e51715a 100644 --- a/theme/bootstrapbase/upgrade.txt +++ b/theme/bootstrapbase/upgrade.txt @@ -7,3 +7,10 @@ Notes: made to the grade report to make it work with Bootstrapbase. Theme developers need to alter config.php and update $THEME->plugins_exclude_sheets to not to list stylesheet from gradereport_grade any more. See MDL-40347 + +=== 2.5.3 === +Notes: +* A new maintenance layout file was introduced. + If you have a theme based upon bootstrapbase that implements its own layouts but + does not define the maintenance layout in its config.php then you may want to + create your own maintenance layout file and apply your customisations to that. diff --git a/theme/clean/layout/maintenance.php b/theme/clean/layout/maintenance.php new file mode 100644 index 00000000000..b483a430355 --- /dev/null +++ b/theme/clean/layout/maintenance.php @@ -0,0 +1,55 @@ +. + +// Get the HTML for the settings bits. +$html = theme_clean_get_html_for_settings($OUTPUT, $PAGE); + +echo $OUTPUT->doctype() ?> +htmlattributes(); ?>> + + <?php echo $OUTPUT->page_title(); ?> + + standard_head_html() ?> + + + +body_attributes(); ?>> + +standard_top_of_body_html() ?> + +
+ + + +
+
+ main_content(); ?> +
+
+ + + + standard_end_of_body_html() ?> + +
+ +