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