3 defined('MOODLE_INTERNAL') || die();
5 $hasheading = $PAGE->heading;
6 $hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar());
7 $hasfooter = (empty($PAGE->layout_options['nofooter']));
9 $hassidepre = (empty($PAGE->layout_options['noblocks']) && $PAGE->blocks->region_has_content('side-pre', $OUTPUT));
10 $haslogininfo = (empty($PAGE->layout_options['nologininfo']));
12 $showsidepre = ($hassidepre && !$PAGE->blocks->region_completely_docked('side-pre', $OUTPUT));
14 $custommenu = $OUTPUT->custom_menu();
15 $hascustommenu = (empty($PAGE->layout_options['nocustommenu']) && !empty($custommenu));
17 $bodyclasses = array();
19 $bodyclasses[] = 'content-only';
23 $bodyclasses[] = 'has_custom_menu';
26 /************************************************************************************************/
27 if (!empty($PAGE->theme->settings->logo)) {
28 $logourl = $PAGE->theme->settings->logo;
30 $logourl = $OUTPUT->pix_url('logo_small', 'theme');
33 $hasframe = !isset($PAGE->theme->settings->noframe) || !$PAGE->theme->settings->noframe;
35 $displaylogo = !isset($PAGE->theme->settings->displaylogo) || $PAGE->theme->settings->displaylogo;
36 /************************************************************************************************/
38 echo $OUTPUT->doctype() ?>
39 <html <?php echo $OUTPUT->htmlattributes() ?>>
41 <title><?php echo $PAGE->title ?></title>
42 <link rel="shortcut icon" href="<?php echo $OUTPUT->pix_url('favicon', 'theme')?>" />
43 <?php echo $OUTPUT->standard_head_html() ?>
45 <body id="<?php p($PAGE->bodyid) ?>" class="<?php p($PAGE->bodyclasses.' '.join(' ', $bodyclasses)) ?>">
46 <?php echo $OUTPUT->standard_top_of_body_html(); ?>
49 <?php if ($hasframe) { ?>
51 <div id="framebottom">
52 <div id="frametopright">
60 <!-- begin of page-header -->
61 <?php if ($hasheading) { ?>
62 <div id="page-header">
63 <?php if ($displaylogo) { ?>
65 <img src="<?php echo $logourl ?>" alt="Custom logo here" />
68 <h1 class="headerheading"><?php echo $PAGE->heading ?></h1>
71 <div class="headermenu">
73 echo $OUTPUT->login_info();
74 if (($CFG->langmenu) && (!empty($PAGE->layout_options['langmenu']))) {
75 echo $OUTPUT->lang_menu();
77 echo $PAGE->headingmenu;
82 <!-- end of page-header -->
84 <!-- begin of custom menu -->
85 <?php if ($hascustommenu) { ?>
86 <div id="custommenu"><?php echo $custommenu; ?></div>
88 <!-- end of custom menu -->
90 <!-- begin of navigation bar -->
91 <?php if ($hasnavbar) { ?>
92 <div class="navbar clearfix">
93 <div class="breadcrumb"><?php echo $OUTPUT->navbar(); ?></div>
94 <div class="navbutton"><?php echo $PAGE->button; ?></div>
97 <!-- end of navigation bar -->
99 <!-- start of moodle content -->
100 <div id="page-content" class="clearfix">
102 <!-- main mandatory content of the moodle page -->
103 <div id="report-main-content">
104 <div class="region-content">
105 <?php echo core_renderer::MAIN_CONTENT_TOKEN ?>
108 <!-- end of main mandatory content of the moodle page -->
110 <!-- left column block - diplayed only if... -->
111 <?php if ($hassidepre) { ?>
112 <div id="report-region-wrap">
113 <div id="report-region-pre" class="block-region">
114 <div class="region-content">
115 <?php echo $OUTPUT->blocks_for_region('side-pre') ?>
120 <!-- end of left column block - diplayed only if... -->
123 <!-- end of moodle content -->
125 <div class="clearfix"></div>
127 <?php if ($hasframe) { ?>
128 </div> <!-- </wrapper> -->
129 </div> <!-- </frameright> -->
130 </div> <!-- </frameleft> -->
131 <div id="framebottomright">
134 </div> <!-- </framebottom> -->
135 </div> <!-- </frametop> -->
142 <!-- START OF FOOTER -->
143 <div id="page-footer">
144 <?php if (!empty($PAGE->theme->settings->footnote)) { ?>
145 <div id="footerframetop">
146 <div id="footerframebottom">
147 <div id="footerframetopright">
150 <div id="footerframeleft">
151 <div id="footerframeright">
153 <!-- the content to show -->
154 <div id="footerwrapper">
155 <?php echo $PAGE->theme->settings->footnote; ?>
156 </div> <!-- </footerwrapper> -->
158 </div> <!-- </footerframeright> -->
159 </div> <!-- </footerframeleft> -->
160 <div id="footerframebottomright">
163 </div> <!-- </footerframebottom> -->
164 </div> <!-- </footerframetop> -->
166 //one more div is waiting to be closed
170 <!-- START OF FOOTER -->
171 <div id="page-footer" class="noframefooter">
172 <?php if (!empty($PAGE->theme->settings->footnote)) { ?>
173 <div id="page-footer-content">
175 <!-- the content to show -->
176 <div id="footerwrapper">
177 <?php echo $PAGE->theme->settings->footnote; ?>
178 </div> <!-- </footerwrapper> -->
180 </div> <!-- </page-footer-content> -->
182 //one more div is waiting to be closed
185 <div class="moodledocsleft">
187 //echo $OUTPUT->login_info();
188 //echo $OUTPUT->home_link();
189 echo $OUTPUT->standard_footer_html();
192 <div class="moodledocs">
193 <?php echo page_doc_link(get_string('moodledocslink')); ?>
195 </div> <!-- </page-footer> -->
196 </div> <!-- </page"> -->
198 <div class="clearfix"></div>
200 <?php } //the waiting div has been closed: </page-footer>
201 echo $OUTPUT->standard_end_of_body_html(); ?>