|
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 $hassidepre = (empty($PAGE->layout_options['noblocks']) && $PAGE->blocks->region_has_content('side-pre', $OUTPUT)); 00007 $hassidepost = (empty($PAGE->layout_options['noblocks']) && $PAGE->blocks->region_has_content('side-post', $OUTPUT)); 00008 00009 $showsidepre = ($hassidepre && !$PAGE->blocks->region_completely_docked('side-pre', $OUTPUT)); 00010 $showsidepost = ($hassidepost && !$PAGE->blocks->region_completely_docked('side-post', $OUTPUT)); 00011 $custommenu = $OUTPUT->custom_menu(); 00012 $hascustommenu = (empty($PAGE->layout_options['nocustommenu']) && !empty($custommenu)); 00013 00014 $bodyclasses = array(); 00015 if ($showsidepre && !$showsidepost) { 00016 $bodyclasses[] = 'side-pre-only'; 00017 } else if ($showsidepost && !$showsidepre) { 00018 $bodyclasses[] = 'side-post-only'; 00019 } else if (!$showsidepost && !$showsidepre) { 00020 $bodyclasses[] = 'content-only'; 00021 } 00022 if ($hascustommenu) { 00023 $bodyclasses[] = 'has_custom_menu'; 00024 } 00025 echo $OUTPUT->doctype() ?> 00026 <html <?php echo $OUTPUT->htmlattributes() ?>> 00027 <head> 00028 <title><?php echo $PAGE->title ?></title> 00029 <link rel="shortcut icon" href="<?php echo $OUTPUT->pix_url('favicon', 'theme')?>" /> 00030 <?php echo $OUTPUT->standard_head_html() ?> 00031 </head> 00032 <body id="<?php p($PAGE->bodyid) ?>" class="<?php p($PAGE->bodyclasses.' '.join(' ', $bodyclasses)) ?>"> 00033 <?php echo $OUTPUT->standard_top_of_body_html() ?> 00034 00035 <div id="page"> 00036 <div id="wrapper" class="clearfix"> 00037 <?php if ($hasheading || $hasnavbar) { ?> 00038 00039 <div id="page-header" class="clearfix"> 00040 00041 <?php if ($hasheading) { ?> 00042 <h1 class="headermain"><?php echo $PAGE->heading ?></h1> 00043 <div class="headermenu"> 00044 <?php 00045 echo $OUTPUT->login_info(); 00046 if (!empty($PAGE->layout_options['langmenu'])) { 00047 echo $OUTPUT->lang_menu(); 00048 } 00049 echo $PAGE->headingmenu 00050 ?> 00051 </div> 00052 <?php } ?> 00053 00054 </div> 00055 00056 <?php if ($hascustommenu) { ?> 00057 <div id="custommenu"><?php echo $custommenu; ?></div> 00058 <?php } ?> 00059 00060 <?php if ($hasnavbar) { ?> 00061 <div class="navbar clearfix"> 00062 <div class="breadcrumb"><?php echo $OUTPUT->navbar(); ?></div> 00063 <div class="navbutton"> <?php echo $PAGE->button; ?></div> 00064 </div> 00065 <?php } ?> 00066 00067 <?php } ?> 00068 00069 <!-- END OF HEADER --> 00070 00071 <div id="page-content-wrapper"> 00072 <div id="page-content"> 00073 <div id="region-main-box"> 00074 <div id="region-post-box"> 00075 00076 <div id="region-main-wrap"> 00077 <div id="region-main"> 00078 <div class="region-content"> 00079 <?php echo $OUTPUT->main_content() ?> 00080 </div> 00081 </div> 00082 </div> 00083 00084 <?php if ($hassidepre) { ?> 00085 <div id="region-pre" class="block-region"> 00086 <div class="region-content"> 00087 <?php echo $OUTPUT->blocks_for_region('side-pre') ?> 00088 </div> 00089 </div> 00090 <?php } ?> 00091 00092 <?php if ($hassidepost) { ?> 00093 <div id="region-post" class="block-region"> 00094 <div class="region-content"> 00095 <?php echo $OUTPUT->blocks_for_region('side-post') ?> 00096 </div> 00097 </div> 00098 <?php } ?> 00099 00100 </div> 00101 </div> 00102 </div> 00103 </div> 00104 00105 </div> 00106 00107 <!-- START OF FOOTER --> 00108 <?php if ($hasfooter) { ?> 00109 <div id="page-footer" class="clearfix"> 00110 <p class="helplink"><?php echo page_doc_link(get_string('moodledocslink')) ?></p> 00111 <?php 00112 echo $OUTPUT->login_info(); 00113 echo $OUTPUT->home_link(); 00114 echo $OUTPUT->standard_footer_html(); 00115 ?> 00116 </div> 00117 <?php } ?> 00118 </div> 00119 <?php echo $OUTPUT->standard_end_of_body_html() ?> 00120 </body> 00121 </html>