source: Dev/trunk/classes/SessionMenu.php @ 59

Last change on this file since 59 was 59, checked in by fpvanagthoven, 14 years ago

Absolutely had to do something about styling. Also some other things.

File size: 1.6 KB
Line 
1<?php
2
3/**
4 * Description of SessionMenu
5 *
6 * @author fpvanagthoven
7 */
8class SessionMenu {
9
10    public function __construct() {
11        ?> <div id="menu1" class="menu"> <?php
12        ?> <div class="menuButtons"> <?php
13        SessionMenu::createSessionButton();
14        SessionMenu::loadSessionButton();
15        SessionMenu::startSessionButton();
16        ?> </div> <?php
17        SessionMenu::loadSessionList(null);
18        ?> </div> <?php
19    }
20
21    public static function createSessionButton() {
22        ?>
23
24        <form action="sessioncreation.php" method="post">
25
26            <input type="submit" value="Create new session" class="surveyButton bigSurveyButton" />
27
28        </form>
29
30        <?php
31    }
32
33    public static function loadSessionButton() {
34        ?>
35        <form id="loadSessionForm" action="sessioncreation.php" method="post">
36            <input type="button" onclick="loadSession()" value="Load/Edit session" class="surveyButton bigSurveyButton" />
37        </form>
38        <?php
39    }
40
41    public static function startSessionButton() {
42        ?>
43        <form action="session.php" method="post">
44            <input type="button" onclick="startSession()" value="Start session" class="surveyButton bigSurveyButton" />
45        </form>
46        <?php
47    }
48
49    public static function loadSessionList($sessions) {
50        ?>
51        <select class="toLoad" size="1000">
52            <?php
53            foreach ($sessions as $session) {
54                ?><option value='<?php echo $session->id; ?>'><?php echo $session->title; ?></option><?php
55        }
56            ?>
57        </select>
58        <?php
59    }
60
61}
62?>
Note: See TracBrowser for help on using the repository browser.