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