diff --git a/theme/boxxie/layout/general.php b/theme/boxxie/layout/general.php index da351b93a5c..5be97ff9683 100644 --- a/theme/boxxie/layout/general.php +++ b/theme/boxxie/layout/general.php @@ -1,4 +1,20 @@ heading); +$hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar()); +$hasfooter = (empty($PAGE->layout_options['nofooter'])); +$hassidepre = $PAGE->blocks->region_has_content('side-pre', $OUTPUT); +$hassidepost = $PAGE->blocks->region_has_content('side-post', $OUTPUT); + +$bodyclasses = array(); +if ($hassidepre && !$hassidepost) { + $bodyclasses[] = 'side-pre-only'; +} else if ($hassidepost && !$hassidepre) { + $bodyclasses[] = 'side-post-only'; +} else if (!$hassidepost && !$hassidepre) { + $bodyclasses[] = 'content-only'; +} + echo $OUTPUT->doctype() ?> htmlattributes() ?>> @@ -7,11 +23,11 @@ echo $OUTPUT->doctype() ?> standard_head_html() ?> - + standard_top_of_body_html() ?> -heading || (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar())) { ?> +
@@ -28,7 +44,7 @@ echo $OUTPUT->doctype() ?> ?>
- layout_options['nonavbar']) && $PAGE->has_navbar()) { ?> +
+
blocks_for_region('side-pre') ?>
- + + +
blocks_for_region('side-post') ?>
+ @@ -79,7 +99,7 @@ echo $OUTPUT->doctype() ?> heading || (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar())) { ?> +if ($hasheading || $hasnavbar) { ?>