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

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

Register correct stylesheet. SessionCreationTool? adjusted.

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