MDL-25589 removing extra align value
[moodle.git] / theme / boxxie / layout / frontpage.php
1 <?php
3 $hasheading = ($PAGE->heading);
4 $hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar());
5 $hasfooter = (empty($PAGE->layout_options['nofooter']));
6 $hassidepre = $PAGE->blocks->region_has_content('side-pre', $OUTPUT);
7 $hassidepost = $PAGE->blocks->region_has_content('side-post', $OUTPUT);
9 $custommenu = $OUTPUT->custom_menu();
10 $hascustommenu = (empty($PAGE->layout_options['nocustommenu']) && !empty($custommenu));
12 $bodyclasses = array();
13 if ($hassidepre && !$hassidepost) {
14     $bodyclasses[] = 'side-pre-only';
15 } else if ($hassidepost && !$hassidepre) {
16     $bodyclasses[] = 'side-post-only';
17 } else if (!$hassidepost && !$hassidepre) {
18     $bodyclasses[] = 'content-only';
19 }
21 if ($hascustommenu) {
22     $bodyclasses[] = 'has-custom-menu';
23 }
25 echo $OUTPUT->doctype() ?>
26 <html <?php echo $OUTPUT->htmlattributes() ?>>
27 <head>
28   <title><?php echo $PAGE->title; ?></title>
29   <link rel="shortcut icon" href="<?php echo $OUTPUT->pix_url('favicon', 'theme')?>" />
30   <?php echo $OUTPUT->standard_head_html() ?>
31 </head>
32  
33 <body id="<?php echo $PAGE->bodyid ?>" class="<?php echo $PAGE->bodyclasses.' '.join(' ', $bodyclasses) ?>">
35 <?php echo $OUTPUT->standard_top_of_body_html() ?>
37 <?php if ($hasheading || $hasnavbar) { ?>
39 <div id="page-wrapper">
40   <div id="page" class="clearfix">
41     
42     <div id="page-header" class="clearfix">
43       <?php if ($PAGE->heading) { ?>
44         <h1 class="headermain"><?php echo $PAGE->heading ?></h1>
45         <div class="headermenu">
46           <?php echo $OUTPUT->login_info();
47           if (!empty($PAGE->layout_options['langmenu'])) {
48             echo $OUTPUT->lang_menu();
49           }
50           echo $PAGE->headingmenu; ?>
51         </div>
52         <?php if ($hascustommenu) { ?>
53         <div id="custommenu"><?php echo $custommenu; ?></div>
54         <?php } ?>
55       <?php } ?>
56     </div>
58 <?php } ?>
59       
60     <div id="page-content">
61         <div id="region-main-box">
62             <div id="region-post-box">
63             
64                 <div id="region-main-wrap">
65                     <div id="region-main">
66                         <div class="region-content">
67                             <?php echo core_renderer::MAIN_CONTENT_TOKEN ?>
68                         </div>
69                     </div>
70                 </div>
71                 
72                 <?php if ($hassidepre) { ?>
73                 <div id="region-pre">
74                     <div class="region-content">
75                         <?php echo $OUTPUT->blocks_for_region('side-pre') ?>
76                     </div>
77                 </div>
78                 <?php } ?>
79                 
80                 <?php if ($hassidepost) { ?>
81                 <div id="region-post">
82                     <div class="region-content">
83                         <?php echo $OUTPUT->blocks_for_region('side-post') ?>
84                     </div>
85                 </div>
86                 <?php } ?>
87                 
88             </div>
89         </div>
90     </div>
91     
92     <div class="clearfix"></div>
93 <?php if ($hasfooter) { ?>
94   
95     <div id="page-footer" class="clearfix">
96       <p class="helplink"><?php echo page_doc_link(get_string('moodledocslink')) ?></p>
97       <?php echo $OUTPUT->login_info(); ?>
98     </div>
99     
100     
101 <?php }
103 if ($hasheading || $hasnavbar) { ?>
104   
105         <div class="myclear"></div>
106   </div> <!-- END #page -->
107   
108 </div> <!-- END #page-wrapper -->
109         
110 <?php } ?>
112 <div id="page-footer-bottom">
114 <?php if ($hasfooter) {
115   echo $OUTPUT->home_link();
116   echo $OUTPUT->standard_footer_html();
117 } ?>
119 </div>     
121 <?php echo $OUTPUT->standard_end_of_body_html() ?>
122 </body>
123 </html>