[ Index ] |
PHP Cross Reference of Unnamed Project |
[Summary view] [Print] [Text view]
1 <?php 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 17 /** 18 * The report layout for the Canvas theme. 19 * 20 * @package theme_canvas 21 * @copyright 2010 Patrick Malley 22 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later 23 */ 24 25 $hasheading = ($PAGE->heading); 26 $hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar()); 27 $hasfooter = (empty($PAGE->layout_options['nofooter'])); 28 $hassidepre = (empty($PAGE->layout_options['noblocks']) && $PAGE->blocks->region_has_content('side-pre', $OUTPUT)); 29 $haslogininfo = (empty($PAGE->layout_options['nologininfo'])); 30 31 $showsidepre = ($hassidepre && !$PAGE->blocks->region_completely_docked('side-pre', $OUTPUT)); 32 33 $custommenu = $OUTPUT->custom_menu(); 34 $hascustommenu = (empty($PAGE->layout_options['nocustommenu']) && !empty($custommenu)); 35 36 $bodyclasses = array(); 37 if ($showsidepre ) { 38 $bodyclasses[] = 'side-pre-only'; 39 } else { 40 $bodyclasses[] = 'content-only'; 41 } 42 if ($hascustommenu) { 43 $bodyclasses[] = 'has_custom_menu'; 44 } 45 46 $courseheader = $coursecontentheader = $coursecontentfooter = $coursefooter = ''; 47 if (empty($PAGE->layout_options['nocourseheaderfooter'])) { 48 $courseheader = $OUTPUT->course_header(); 49 $coursecontentheader = $OUTPUT->course_content_header(); 50 if (empty($PAGE->layout_options['nocoursefooter'])) { 51 $coursecontentfooter = $OUTPUT->course_content_footer(); 52 $coursefooter = $OUTPUT->course_footer(); 53 } 54 } 55 56 echo $OUTPUT->doctype() ?> 57 <html <?php echo $OUTPUT->htmlattributes() ?>> 58 <head> 59 <title><?php echo $PAGE->title ?></title> 60 <link rel="shortcut icon" href="<?php echo $OUTPUT->pix_url('favicon', 'theme')?>" /> 61 <?php echo $OUTPUT->standard_head_html() ?> 62 </head> 63 <body id="<?php p($PAGE->bodyid) ?>" class="<?php p($PAGE->bodyclasses.' '.join(' ', $bodyclasses)) ?>"> 64 <?php echo $OUTPUT->standard_top_of_body_html() ?> 65 66 <div id="page"> 67 68 <!-- START OF HEADER --> 69 70 <?php if ($hasheading || $hasnavbar || !empty($courseheader) || !empty($coursefooter)) { ?> 71 <div id="wrapper" class="clearfix"> 72 <?php } ?> 73 74 <?php if ($hasheading) { ?> 75 <div id="page-header"> 76 <div id="page-header-wrapper" class="clearfix"> 77 <h1 class="headermain"><?php echo $PAGE->heading ?></h1> 78 <div class="headermenu"> 79 <?php 80 echo $OUTPUT->login_info(); 81 if (!empty($PAGE->layout_options['langmenu'])) { 82 echo $OUTPUT->lang_menu(); 83 } 84 echo $PAGE->headingmenu; 85 ?> 86 </div> 87 </div> 88 </div> 89 <?php } ?> 90 91 <?php if ($hascustommenu) { ?> 92 <div id="custommenu"><?php echo $custommenu; ?></div> 93 <?php } ?> 94 95 <?php if (!empty($courseheader)) { ?> 96 <div id="course-header"><?php echo $courseheader; ?></div> 97 <?php } ?> 98 99 <?php if ($hasnavbar) { ?> 100 <div class="navbar clearfix"> 101 <div class="breadcrumb"><?php echo $OUTPUT->navbar(); ?></div> 102 <div class="navbutton"> <?php echo $PAGE->button; ?></div> 103 </div> 104 <?php } ?> 105 106 <!-- END OF HEADER --> 107 108 <!-- START OF CONTENT --> 109 110 111 <div id="page-content-wrapper" class="clearfix"> 112 <div id="page-content"> 113 <div id="report-main-content"> 114 <div class="region-content"> 115 <?php echo $coursecontentheader; ?> 116 <?php echo $OUTPUT->main_content() ?> 117 <?php echo $coursecontentfooter; ?> 118 </div> 119 </div> 120 <?php if ($hassidepre) { ?> 121 <div id="report-region-wrap"> 122 <div id="report-region-pre" class="block-region"> 123 <div class="region-content"> 124 <?php echo $OUTPUT->blocks_for_region('side-pre') ?> 125 </div> 126 </div> 127 </div> 128 <?php } ?> 129 </div> 130 </div> 131 132 <!-- END OF CONTENT --> 133 134 <!-- START OF FOOTER --> 135 136 <?php if (!empty($coursefooter)) { ?> 137 <div id="course-footer"><?php echo $coursefooter; ?></div> 138 <?php } ?> 139 <?php if ($hasfooter) { ?> 140 <div id="page-footer" class="clearfix"> 141 <p class="helplink"><?php echo page_doc_link(get_string('moodledocslink')) ?></p> 142 <?php 143 echo $OUTPUT->login_info(); 144 echo $OUTPUT->home_link(); 145 echo $OUTPUT->standard_footer_html(); 146 ?> 147 </div> 148 <?php } ?> 149 150 <?php if ($hasheading || $hasnavbar || !empty($courseheader) || !empty($coursefooter)) { ?> 151 </div> <!-- END #wrapper --> 152 <?php } ?> 153 154 </div> <!-- END #page --> 155 156 <?php echo $OUTPUT->standard_end_of_body_html() ?> 157 </body> 158 </html>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Thu Aug 11 10:00:09 2016 | Cross-referenced by PHPXref 0.7.1 |