$pages = array();
$templates = array();
-$files = array('about','tickets','food','ents','committee','sponsorship','charity','workers');
+$files = array('splash','about','tickets','food','ents','committee','sponsorship','charity','workers');
foreach($files as $page){
if(is_file('page/' . $page . '.php') && is_file('template/' . $page . '.php')){
if(isset($_GET['page']) && isset($templates[$_GET['page']])){
$current = $_GET['page'];
-} elseif(isset($templates['about'])){
- $current = 'about';
+} elseif(isset($templates['splash'])){
+ $current = 'splash';
} elseif(count($templates) > 0) {
$current = array_shift(array_keys($templates));
}
--- /dev/null
+<?php
+
+class Page_Splash extends Page {
+
+ public function execute($template){
+
+ }
+
+
+}
class Template_About extends Template {
-
+function display(){
+ ?><img src="/theme/about.png"><?
+}
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></script>
<script src="theme/hmb.js"></script>
<script>
- hmb_setup(<?php echo $this->keys[$this->current]; ?>,<?php echo count($this->keys); ?>, {
+ hmb_setup(/* current */ <?php echo $this->keys[$this->current]; ?>, /* number */ <?php echo count($this->keys); ?>, {
<?php
foreach($this->keys as $name => $i){
</script>
</head>
<body>
- <div id="wrapper">
<div id="logo">
<a href="/"><img src="theme/logo.png"></a>
</div>
<div class="arrow" id="arrow-l" <?php if(!($this->keys[$this->current] > 0)){ ?> style="display: none;" <?php } ?>>
<a href="-1"><img src="theme/left.png"></a>
</div>
- <ul id="panes" style="left: -<?php echo $this->keys[$this->current] * 80; ?>%;">
+ <div id="paneshow" style="left: <?php echo -1 * $this->keys[$this->current] * 850; ?>px;">
+ <div id="panebar">
+ <ul id="panes">
<?php
if(count($this->templates) == 0){
?>
} else {
foreach($this->templates as $name => $template){
?>
- <li class="pane pane-<?php echo ($this->keys[$name] % 2) == 0 ? 'r' : 'p'; ?>" style="left: <?php echo ($this->keys[$name] * 80) + 10; ?>%;" id="pane-<?php echo $name; ?>">
- <div class="content">
- <?php $template->display(); ?>
- </div>
+ <li class="pane pane-<?php echo ($this->keys[$name] % 2) == 0 ? 'r' : 'p'; ?>" style="left: <?php echo ($this->keys[$name] * 850); ?>px;" id="pane-<?php echo $name; ?>">
+ <div class="content"><?php $template->display(); ?></div>
</li>
<?php
}
}
?>
</ul>
+ </div>
+ </div>
<div class="arrow" id="arrow-r">
<a href="<?php echo $this->numbers[$this->keys[$this->current] + 1]; ?>"><img src="theme/right.png"></a>
</div>
+ <div id="footer">
+ © 2010 Homerton May Ball Committee. All rights reserved.
+ </div>
</div>
- <div id="footer">
- © 2010 Homerton May Ball Committee. All rights reserved.
- </div>
- </div>
</body>
</html>
<?php
--- /dev/null
+<?php
+
+class Template_Splash extends Template {
+
+public function display(){
+ ?><img src="/theme/splash.png"><?
+}
+
+}
/** Homerton May Ball CSS File - Richard Whitehouse **/
+
body {
margin: 0;
padding: 0;
}
div#wrapper {
- overflow: hidden;
- position: absolute;
- top: 0;
- bottom: 20px;
- left: 0;
- right: 0;
}
+
div#logo {
z-index: 20;
position: absolute;
div#navbar {
background: black;
- width: 70%;
+ width: 700px;
height: 40px;
position: absolute;
- left: 15%;
- right: 15%;
+ left: 50%;
+ margin-left: -350px;
top: 104px;
z-index: 10;
}
position: absolute;
left: 0;
right: 0;
+ height: 530px;
top: 124px;
- bottom: 20px;
+ overflow: hidden;
}
div.arrow {
position: absolute;
top: 50%;
height: 40px;
- margin-top: -20px;
+ margin-top: -60px;
}
div#arrow-l {
- left: 10%;
+ left: 50%;
+ margin-left: -420px;
}
div#arrow-r {
- right: 10%;
+ right: 50%;
+ margin-right: -420px;
+}
+
+div#paneshow {
+ margin: 0;
+ padding: 0;
+ position: relative;
+ top: 0;
+ height: 100%;
+}
+
+div#panebar {
+ position: absolute;
+ left:50%;
+ top: 0px;
+ margin-left: -425px;
+ bottom: 0px;
+ width: 100%;
}
ul#panes {
margin: 0;
position: relative;
top: 0;
- height: 100%;
+ height: 500px;
}
ul#panes li.pane {
display: block;
- width: 80%;
+ width: 850px;
+ height: 500px;
background: white;
- height: 100%;
position: absolute;
z-index: 3;
- padding: 1px;
overflow: hidden;
}
}
div.content {
- height: 100%;
- overflow: auto;
- padding: 20px;
+ width: 850px;
+ height: 500px;
+ overflow: visible;
color: white;
}
div#footer {
z-index: 10;
background: black;
- width: 70%;
+ width: 700px;
position: absolute;
- left: 15%;
- right: 15%;
- bottom: 0;
+ left: 50%;
+ margin-left: -350px;
+ bottom: 10px;
height: 40px;
line-height: 40px;
font-size: 14px;
font-weight: black;
font-family: Verdana, Arial, sans-serif;
}
+
function update_hmb(){
$("#arrow-l,#arrow-r").hide();
- var left = current * 80;
- $("#panes").animate({ left: "-" + left + "%" }, function(){
+ var left = current * 850;
+ $("#paneshow").animate({ left: "-" + left + "px" }, function(){
if(current > 0){
$("#arrow-l").fadeIn('slow');