mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +02:00
Building theme
This commit is contained in:
parent
2a56765822
commit
4f68869bf6
3 changed files with 172 additions and 51 deletions
|
@ -35,11 +35,13 @@ $THEME->enable_dock = false;
|
|||
// Do you want to use the new navigation dock?
|
||||
////////////////////////////////////////////////////
|
||||
|
||||
|
||||
$THEME->layouts = array(
|
||||
'base' => array(
|
||||
'theme' => 'boxxie',
|
||||
'file' => 'general.php',
|
||||
'regions' => array(),
|
||||
'regions' => array('side-pre', 'side-post'),
|
||||
'defaultregion' => 'side-post',
|
||||
),
|
||||
'general' => array(
|
||||
'theme' => 'boxxie',
|
||||
|
@ -115,3 +117,12 @@ $THEME->layouts = array(
|
|||
'options' => array('nofooter'=>true, 'nonavbar'=>true),
|
||||
),
|
||||
);
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// These are all of the possible layouts in Moodle. The
|
||||
// simplest way to do this is to keep the theme and file
|
||||
// variables the same for every layout. Including them
|
||||
// all in this way allows some flexibility down the road
|
||||
// if you want to add a different layout template to a
|
||||
// specific page.
|
||||
///////////////////////////////////////////////////////////////
|
|
@ -8,9 +8,14 @@ echo $OUTPUT->doctype() ?>
|
|||
</head>
|
||||
|
||||
<body id="<?php echo $PAGE->bodyid; ?>" class="<?php echo $PAGE->bodyclasses; ?>">
|
||||
|
||||
<?php echo $OUTPUT->standard_top_of_body_html() ?>
|
||||
<div id="page">
|
||||
|
||||
<?php if ($PAGE->heading || (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar())) { ?>
|
||||
|
||||
<div id="page-wrapper">
|
||||
<div id="page" class="clearfix">
|
||||
|
||||
<div id="page-header">
|
||||
<?php if ($PAGE->heading) { ?>
|
||||
<h1 class="headermain"><?php echo $PAGE->heading ?></h1>
|
||||
|
@ -20,7 +25,9 @@ echo $OUTPUT->doctype() ?>
|
|||
echo $OUTPUT->lang_menu();
|
||||
}
|
||||
echo $PAGE->headingmenu
|
||||
?></div><?php } ?>
|
||||
?></div><?php
|
||||
} ?>
|
||||
|
||||
<?php if (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar()) { ?>
|
||||
<div class="navbar clearfix">
|
||||
<div class="breadcrumb"><?php echo $OUTPUT->navbar(); ?></div>
|
||||
|
@ -28,11 +35,13 @@ echo $OUTPUT->doctype() ?>
|
|||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<?php } ?>
|
||||
|
||||
<div id="page-content">
|
||||
<div id="regions">
|
||||
<div id="regions-mask">
|
||||
|
||||
<div id="region-main">
|
||||
<div id="region-main-mask">
|
||||
<div class="region-content">
|
||||
|
@ -40,21 +49,25 @@ echo $OUTPUT->doctype() ?>
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="region-pre">
|
||||
<div class="region-content">
|
||||
<?php echo $OUTPUT->blocks_for_region('side-pre') ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="region-post">
|
||||
<div class="region-content">
|
||||
<?php echo $OUTPUT->blocks_for_region('side-post') ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php if ($hasfooter) { ?>
|
||||
<?php if ($hasfooter) { ?>
|
||||
|
||||
<div id="page-footer" class="clearfix">
|
||||
<p class="helplink"><?php echo page_doc_link(get_string('moodledocslink')) ?></p>
|
||||
<?php
|
||||
|
@ -63,8 +76,17 @@ echo $OUTPUT->doctype() ?>
|
|||
echo $OUTPUT->standard_footer_html();
|
||||
?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<?php }
|
||||
|
||||
if ($PAGE->heading || (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar())) { ?>
|
||||
|
||||
</div> <!-- END #page -->
|
||||
</div> <!-- END #page-wrapper -->
|
||||
|
||||
<?php } ?>
|
||||
|
||||
|
||||
<?php echo $OUTPUT->standard_end_of_body_html() ?>
|
||||
</body>
|
||||
</html>
|
|
@ -1 +1,89 @@
|
|||
body {}
|
||||
html {
|
||||
background: #6e8c45;
|
||||
}
|
||||
|
||||
#page-wrapper {
|
||||
margin: 10px 5%;
|
||||
background: #5b7439;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
#page {
|
||||
background: #fff;
|
||||
padding: 5px;
|
||||
width: auto;
|
||||
}
|
||||
|
||||
a:link,
|
||||
a:visited {
|
||||
color: #69804e;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:hover,
|
||||
a:active {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
/* Header */
|
||||
|
||||
#page-header {
|
||||
background: #3b4c25;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
#page-header a:link,
|
||||
#page-header a:visited {
|
||||
color: #b3c79d;
|
||||
}
|
||||
|
||||
#page-header h1.headermain {
|
||||
color: #fff;
|
||||
font-weight: normal;
|
||||
margin:1em;
|
||||
}
|
||||
|
||||
.sideblock {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.sideblock .header {
|
||||
background: #69804e;
|
||||
padding:2px 5px;
|
||||
}
|
||||
|
||||
.sideblock .header h2 {
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.sideblock .content {
|
||||
background: #f3f8ed;
|
||||
border-width: 1px;
|
||||
border-color: #69804e;
|
||||
border-style: solid;
|
||||
}
|
||||
|
||||
/* Course */
|
||||
|
||||
.coursebox {
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.coursebox h3.name {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.categorybox {
|
||||
border: none;
|
||||
}
|
||||
|
||||
h2.headingblock {
|
||||
font-weight: normal;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
/* Forum */
|
||||
|
||||
.forumpost .topic {
|
||||
background: #c9dfb2;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue