MDL-41511 blocks: improved how custom block regions were being rendered.
[moodle.git] / theme / base / config.php
CommitLineData
78946b9b 1<?php
78946b9b
PS
2// This file is part of Moodle - http://moodle.org/
3//
4// Moodle is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// Moodle is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
16
78946b9b 17/**
91266444 18 * Configuration for Moodle's base theme.
78946b9b 19 *
91266444
MD
20 * This theme is special, and implements a minimalist theme with only
21 * basic layout. It is intended as a base for other themes to build upon.
22 * It is not recommend to actually choose this theme for production sites!
78946b9b 23 *
ed5d13c0 24 * DO NOT COPY THIS TO START NEW THEMES!
91266444 25 * Start with another theme, like "standard".
78946b9b 26 *
91266444 27 * For full information about creating Moodle themes, see:
728ebac7 28 * http://docs.moodle.org/dev/Themes_2.0
78946b9b 29 *
574909ef 30 * @package theme_base
78946b9b
PS
31 * @copyright 2009 Tim Hunt
32 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
33 */
34
90723839 35$THEME->name = 'base';
78946b9b
PS
36
37$THEME->parents = array();
38
39$THEME->sheets = array(
36520392
SH
40 'pagelayout', // Must come first: Page layout.
41 'core', // Must come second: General styles.
90723839 42 'admin',
78946b9b 43 'blocks',
90723839 44 'calendar',
78946b9b 45 'course',
7e4617f7 46 'dock',
90723839
SH
47 'grade',
48 'message',
49 'question',
b5e7b638
MG
50 'user',
51 'filemanager'
78946b9b
PS
52);
53
ca194849 54$THEME->editor_sheets = array('editor');
78946b9b
PS
55
56$THEME->layouts = array(
36520392 57 // Most backwards compatible layout without the blocks - this is the layout used by default.
191b267b 58 'base' => array(
191b267b
PS
59 'file' => 'general.php',
60 'regions' => array(),
61 ),
36520392 62 // Standard layout with blocks, this is recommended for most pages with general information.
191b267b 63 'standard' => array(
78946b9b
PS
64 'file' => 'general.php',
65 'regions' => array('side-pre', 'side-post'),
96e0e914 66 'defaultregion' => 'side-pre',
78946b9b 67 ),
36520392 68 // Main course page.
78946b9b 69 'course' => array(
78946b9b
PS
70 'file' => 'general.php',
71 'regions' => array('side-pre', 'side-post'),
96e0e914 72 'defaultregion' => 'side-pre',
244a32c6 73 'options' => array('langmenu'=>true),
191b267b
PS
74 ),
75 'coursecategory' => array(
191b267b
PS
76 'file' => 'general.php',
77 'regions' => array('side-pre', 'side-post'),
96e0e914 78 'defaultregion' => 'side-pre',
191b267b 79 ),
36520392 80 // Part of course, typical for modules - default page layout if $cm specified in require_login().
191b267b 81 'incourse' => array(
191b267b
PS
82 'file' => 'general.php',
83 'regions' => array('side-pre', 'side-post'),
96e0e914 84 'defaultregion' => 'side-pre',
78946b9b
PS
85 ),
86 // The site home page.
191b267b 87 'frontpage' => array(
191b267b 88 'file' => 'frontpage.php',
78946b9b 89 'regions' => array('side-pre', 'side-post'),
96e0e914 90 'defaultregion' => 'side-pre',
78946b9b
PS
91 ),
92 // Server administration scripts.
93 'admin' => array(
78946b9b
PS
94 'file' => 'general.php',
95 'regions' => array('side-pre'),
191b267b 96 'defaultregion' => 'side-pre',
78946b9b 97 ),
36520392 98 // My dashboard page.
191b267b 99 'mydashboard' => array(
78946b9b
PS
100 'file' => 'general.php',
101 'regions' => array('side-pre', 'side-post'),
96e0e914 102 'defaultregion' => 'side-pre',
244a32c6 103 'options' => array('langmenu'=>true),
78946b9b 104 ),
36520392 105 // My public page.
191b267b 106 'mypublic' => array(
191b267b
PS
107 'file' => 'general.php',
108 'regions' => array('side-pre', 'side-post'),
96e0e914 109 'defaultregion' => 'side-pre',
191b267b
PS
110 ),
111 'login' => array(
78946b9b
PS
112 'file' => 'general.php',
113 'regions' => array(),
244a32c6 114 'options' => array('langmenu'=>true),
78946b9b 115 ),
191b267b 116
78946b9b
PS
117 // Pages that appear in pop-up windows - no navigation, no blocks, no header.
118 'popup' => array(
78946b9b
PS
119 'file' => 'general.php',
120 'regions' => array(),
fdd4b9a5 121 'options' => array('nofooter'=>true, 'nonavbar'=>true, 'nocustommenu'=>true, 'nologininfo'=>true, 'nocourseheaderfooter'=>true),
78946b9b
PS
122 ),
123 // No blocks and minimal footer - used for legacy frame layouts only!
124 'frametop' => array(
78946b9b
PS
125 'file' => 'general.php',
126 'regions' => array(),
fdd4b9a5 127 'options' => array('nofooter'=>true, 'nocoursefooter'=>true),
78946b9b 128 ),
36520392 129 // Embeded pages, like iframe/object embeded in moodleform - it needs as much space as possible.
78946b9b 130 'embedded' => array(
78946b9b
PS
131 'file' => 'embedded.php',
132 'regions' => array(),
fdd4b9a5 133 'options' => array('nofooter'=>true, 'nonavbar'=>true, 'nocustommenu'=>true, 'nocourseheaderfooter'=>true),
78946b9b
PS
134 ),
135 // Used during upgrade and install, and for the 'This site is undergoing maintenance' message.
136 // This must not have any blocks, and it is good idea if it does not have links to
137 // other places - for example there should not be a home link in the footer...
138 'maintenance' => array(
78946b9b
PS
139 'file' => 'general.php',
140 'regions' => array(),
fdd4b9a5 141 'options' => array('noblocks'=>true, 'nofooter'=>true, 'nonavbar'=>true, 'nocustommenu'=>true, 'nocourseheaderfooter'=>true),
78946b9b 142 ),
ed5d13c0
PS
143 // Should display the content and basic headers only.
144 'print' => array(
145 'file' => 'general.php',
146 'regions' => array(),
fdd4b9a5 147 'options' => array('noblocks'=>true, 'nofooter'=>true, 'nonavbar'=>false, 'nocustommenu'=>true, 'nocourseheaderfooter'=>true),
ed5d13c0 148 ),
96321cf4
SH
149 // The pagelayout used when a redirection is occuring.
150 'redirect' => array(
151 'file' => 'embedded.php',
152 'regions' => array(),
fdd4b9a5 153 'options' => array('nofooter'=>true, 'nonavbar'=>true, 'nocustommenu'=>true, 'nocourseheaderfooter'=>true),
96321cf4 154 ),
2d0e682d 155 // The pagelayout used for reports.
367a75fa
SH
156 'report' => array(
157 'file' => 'report.php',
158 'regions' => array('side-pre'),
159 'defaultregion' => 'side-pre',
160 ),
2d0e682d
MV
161 // The pagelayout used for safebrowser and securewindow.
162 'secure' => array(
163 'file' => 'general.php',
b5cd5f83
MV
164 'regions' => array('side-pre', 'side-post'),
165 'defaultregion' => 'side-pre',
fdd4b9a5 166 'options' => array('nofooter'=>true, 'nonavbar'=>true, 'nocustommenu'=>true, 'nologinlinks'=>true, 'nocourseheaderfooter'=>true),
2d0e682d 167 ),
78946b9b
PS
168);
169
4d56ee95
SH
170// We don't want the base theme to be shown on the theme selection screen, by setting
171// this to true it will only be shown if theme designer mode is switched on.
172$THEME->hidefromselector = true;
173
358c13cb 174/** List of javascript files that need to included on each page */
9d897331 175$THEME->javascripts = array();
91266444 176$THEME->javascripts_footer = array();
225c418f
SH
177
178// Set this to the method you will use in your layout files for
179$THEME->blockrendermethod = 'blocks_for_region';