|
Moodle
2.2.1
http://www.collinsharper.com
|
00001 <?php 00002 00003 $hasheading = ($PAGE->heading); 00004 $hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar()); 00005 $hasfooter = (empty($PAGE->layout_options['nofooter'])); 00006 $hassidepost = (empty($PAGE->layout_options['noblocks']) && $PAGE->blocks->region_has_content('side-post', $OUTPUT)); 00007 00008 $showsidepost = ($hassidepost && !$PAGE->blocks->region_completely_docked('side-post', $OUTPUT)); 00009 00010 $custommenu = $OUTPUT->custom_menu(); 00011 $hascustommenu = (empty($PAGE->layout_options['nocustommenu']) && !empty($custommenu)); 00012 00013 $bodyclasses = array(); 00014 if ($showsidepost) { 00015 $bodyclasses[] = 'side-post-only'; 00016 } else if (!$showsidepost) { 00017 $bodyclasses[] = 'content-only'; 00018 } 00019 if ($hascustommenu) { 00020 $bodyclasses[] = 'has_custom_menu'; 00021 } 00022 00023 if (!empty($PAGE->theme->settings->footertext)) { 00024 $footnote = $PAGE->theme->settings->footertext; 00025 } else { 00026 $footnote = '<!-- There was no custom footnote set -->'; 00027 } 00028 00029 00030 echo $OUTPUT->doctype() ?> 00031 <html <?php echo $OUTPUT->htmlattributes() ?>> 00032 <head> 00033 <title><?php echo $PAGE->title ?></title> 00034 <link rel="shortcut icon" href="<?php echo $OUTPUT->pix_url('favicon', 'theme')?>" /> 00035 <?php echo $OUTPUT->standard_head_html() ?> 00036 </head> 00037 00038 <body id="<?php p($PAGE->bodyid) ?>" class="<?php p($PAGE->bodyclasses.' '.join(' ', $bodyclasses)) ?>"> 00039 <?php echo $OUTPUT->standard_top_of_body_html() ?> 00040 00041 <div id="page"> 00042 00043 <?php if ($hasheading || $hasnavbar) { ?> 00044 00045 <div id="page-wrap1"> 00046 <div id="page-wrap2"> 00047 00048 <div id="wrapper" class="clearfix"> 00049 00050 <!-- START OF HEADER --> 00051 00052 <div id="page-header" class="inside"> 00053 <div id="page-header-wrapper" class="wrapper clearfix"> 00054 00055 <?php if ($hasheading) { ?> 00056 <div id="headermenus" class="clearfix"> 00057 <div class="headermenu"> 00058 <?php if (!empty($PAGE->layout_options['langmenu'])) { 00059 echo $OUTPUT->lang_menu(); 00060 } 00061 echo $OUTPUT->login_info(); 00062 echo $PAGE->headingmenu 00063 ?> 00064 </div> 00065 <?php if ($hascustommenu) { ?> 00066 <div id="custommenu"><?php echo $custommenu; ?></div> 00067 <?php } else { ?> 00068 <div id="custommenu" style="line-height:1em;"> </div> <!-- temporary until I find a better fix --> 00069 <?php } ?> 00070 </div> 00071 <?php } ?> 00072 00073 </div> 00074 </div> 00075 00076 <!-- END OF HEADER --> 00077 00078 <?php } ?> 00079 00080 00081 <!-- START OF CONTENT --> 00082 00083 <div id="page-content-wrapper" class="wrapper clearfix"> 00084 <div id="page-content"> 00085 <div id="region-main-box"> 00086 <div id="region-post-box"> 00087 00088 <div id="region-main-wrap"> 00089 <div id="region-main"> 00090 <div class="region-content"> 00091 00092 <div id="region-header" class="inside"> 00093 <h1 class="headermain"><?php echo $PAGE->heading ?></h1> 00094 </div> 00095 00096 <?php if ($hasnavbar) { ?> 00097 <div class="navbar"> 00098 <div class="wrapper clearfix"> 00099 <div class="breadcrumb"> 00100 <?php echo $OUTPUT->navbar(); ?> 00101 </div> 00102 <div class="navbutton"> 00103 <?php echo $PAGE->button; ?> 00104 </div> 00105 </div> 00106 </div> 00107 <?php } ?> 00108 00109 <?php echo $OUTPUT->main_content() ?> 00110 </div> 00111 </div> 00112 </div> 00113 00114 <?php if ($hassidepost) { ?> 00115 <div id="region-post" class="block-region"> 00116 <div id="region-post-wrap-1"> 00117 <div id="region-post-wrap-2"> 00118 <div class="region-content"> 00119 <?php echo $OUTPUT->blocks_for_region('side-post') ?> 00120 </div> 00121 </div> 00122 </div> 00123 </div> 00124 <?php } ?> 00125 00126 </div> 00127 </div> 00128 </div> 00129 </div> 00130 00131 <!-- END OF CONTENT --> 00132 00133 <?php if ($hasheading || $hasnavbar) { ?> 00134 </div> 00135 00136 </div> 00137 </div> 00138 00139 00140 <?php } ?> 00141 00142 <!-- START OF FOOTER --> 00143 00144 <?php if ($hasfooter) { ?> 00145 <div id="page-footer" class="wrapper"> 00146 <?php echo $footnote ?> 00147 <p class="helplink"><?php echo page_doc_link(get_string('moodledocslink')) ?></p> 00148 <?php 00149 echo $OUTPUT->login_info(); 00150 echo $OUTPUT->home_link(); 00151 echo $OUTPUT->standard_footer_html(); 00152 ?> 00153 </div> 00154 <?php } ?> 00155 00156 </div> 00157 <?php echo $OUTPUT->standard_end_of_body_html() ?> 00158 </body> 00159 </html>