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