bzr branch
http://gegoxaren.bato24.eu/bzr/lenasys/trunk
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
1 |
<!-- bannermenu.php -->
|
2 |
<div id="bannerBody"> |
|
3 |
||
4 |
<!-- This div contains the bannermenu and centers it on the page --> |
|
5 |
<div id="bannerWrapper"> |
|
6 |
|
|
7 |
<!-- Determines how the LenaSYSButton should look and function depending on if the user is logged in or not --> |
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
8 |
<?php |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
9 |
//$userName
|
10 |
$url = base_url(); |
|
11 |
||
12 |
//If user is logged in
|
|
|
85.2.1
by a11emmjo
Combined bannermenu with startview to get correct start-page. |
13 |
if($userName != '') { |
14 |
$url = base_url().'cms'; |
|
|
90.1.9
by a11emmjo
Updated branch. |
15 |
}
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
16 |
|
17 |
echo '<a href="'.$url.'" title="Home"><div id="bannerLogoButton"></div></a>'; |
|
18 |
?>
|
|
19 |
|
|
20 |
<!-- This div contains all the content between the LenaSYS button and the user button --> |
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
21 |
<div id="bannerContent"> |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
22 |
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
23 |
<!-- This div contains the content that is needed on the banner for the CMS page. |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
24 |
The name is only used to set it hidden or shown. -->
|
25 |
<div id="bannerContentCMS"> |
|
26 |
|
|
27 |
<!-- Determines if the header should contain active course info depending on if the user is logged in or not --> |
|
28 |
<?php |
|
29 |
//$userName
|
|
30 |
//$activeCourse
|
|
|
90.1.9
by a11emmjo
Updated branch. |
31 |
$header = ''; |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
32 |
|
|
90.1.9
by a11emmjo
Updated branch. |
33 |
//If user is logged in
|
|
85.2.1
by a11emmjo
Combined bannermenu with startview to get correct start-page. |
34 |
if($userName != '') { |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
35 |
$header = '<span id="bannerHeaderCMSCourseName">'. |
|
90.1.9
by a11emmjo
Updated branch. |
36 |
$activeCourse['courseName'].' </span><span id="bannerHeaderCMSCourseCode">- '. |
37 |
$activeCourse['courseID'].'</span>'; |
|
38 |
}
|
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
39 |
|
40 |
echo '<div id="bannerHeaderCMS">'.$header.'</div>'; |
|
41 |
?>
|
|
42 |
|
|
43 |
</div> |
|
44 |
|
|
45 |
<!-- This div contains the content that is needed on the banner for the example page. |
|
46 |
The name is only used to set it hidden or shown. -->
|
|
47 |
<div id="bannerContentExample"> |
|
48 |
|
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
49 |
<!-- This div contains the dropdownmenu for the codeviewer menu button --> |
50 |
<div id="dropdownCodeviewerMenu"> |
|
51 |
<div class="drowdownMenuHeader">Choose example</div> |
|
52 |
<a href="#"><div class="dropdownMenuButton">Menu with images using divs</div></a> |
|
53 |
<a href="#"><div class="dropdownMenuButton">Dropdown menu</div></a> |
|
54 |
<a href="#"><div class="dropdownMenuButton">Expand and contract data</div></a> |
|
55 |
</div> |
|
56 |
|
|
57 |
<a href="#" title="Open example menu"><div id="bannerCodeviewerMenuButton" class="icomoon">%</div></a> |
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
58 |
<a href="#" title="Go to previous example"><div id="bannerLeftArrowButton" class="icomoon">&</div></a> |
59 |
<a href="#" title="Go to next example"><div id="bannerRightArrowButton" class="icomoon">'</div></a> |
|
60 |
<a href="#" title="Play the example"><div id="bannerPlayButton" class="icomoon">-</div></a> |
|
61 |
<div id="bannerHeaderExample">Menu with images using divs</div> |
|
62 |
<a href="#" title=""><div id="bannerExtraButton" class="icomoon">+</div></a> |
|
63 |
</div> |
|
64 |
|
|
65 |
</div><!-- End of bannerContent --> |
|
66 |
|
|
67 |
<!-- Determines how the userMenuButton should look and function depending on if the user is logged in or not --> |
|
68 |
<?php |
|
69 |
//$userName
|
|
70 |
$title = ''; |
|
71 |
$text = ''; |
|
72 |
||
73 |
if($userName == '') { |
|
74 |
$title = 'Click to login'; |
|
75 |
$text = 'Login'; |
|
76 |
}
|
|
77 |
else if($userName != '') { |
|
78 |
$title = 'Open settings menu'; |
|
79 |
$text = $userName; |
|
80 |
}
|
|
81 |
||
82 |
echo '<div id="bannerUserMenuButton" title="'.$title.'">'.$text.'</div>'; |
|
|
67.1.6
by a11emmjo
Replaced bannermenu/topmenu/header... on login-page. |
83 |
?>
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
84 |
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
85 |
<!-- This div contains the dropdownmenu for user menu button --> |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
86 |
<div id="dropdownUserMenu"> |
87 |
<div class="drowdownMenuHeader">Settings</div> |
|
88 |
<div id="dropdownMenuExpandCourses" class="dropdownMenuButton"> |
|
|
90.1.9
by a11emmjo
Updated branch. |
89 |
Courses<span id="dropdownMenuButtonArrow"> </span> |
90 |
</div> |
|
91 |
<div id="dropdownMenuCourseBlock"> |
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
92 |
<ul> |
93 |
<?php |
|
|
85.2.1
by a11emmjo
Combined bannermenu with startview to get correct start-page. |
94 |
//$courses
|
95 |
//$activeCourse
|
|
|
90.1.9
by a11emmjo
Updated branch. |
96 |
|
|
85.2.1
by a11emmjo
Combined bannermenu with startview to get correct start-page. |
97 |
foreach($courses as $course) { |
98 |
if($course->courseID == $activeCourse['courseID']) { |
|
|
90.1.9
by a11emmjo
Updated branch. |
99 |
echo '<li class="dropdownMenuCourseBlockActiveCourse">' |
100 |
.$course->name.' - '.$course->courseID; |
|
101 |
echo '</li>'; |
|
102 |
}
|
|
103 |
else { |
|
104 |
echo '<li>' |
|
105 |
.$course->name.' - '.$course->courseID; |
|
106 |
echo '</li>'; |
|
107 |
}
|
|
108 |
}
|
|
|
85.2.1
by a11emmjo
Combined bannermenu with startview to get correct start-page. |
109 |
?>
|
110 |
</ul> |
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
111 |
<hr> |
112 |
<p>Manage Courses</p> |
|
|
90.1.9
by a11emmjo
Updated branch. |
113 |
</div> |
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
114 |
<div class="dropdownMenuButton" id="dropdownMenuAddInstructor">Add Instructor</div> |
|
83.2.20
by elof.bigestans at gmail
Working on Bannermenu |
115 |
<div class="dropdownMenuButton" id="dropdownMenuChangePassword">Change Password</div> |
116 |
<div class="dropdownMenuButton" id="dropdownMenuLogout">Logout</div> |
|
117 |
</div> |
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
118 |
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
119 |
<!-- This div contains the all the popups needed for this view --> |
|
90.1.5
by a11emmjo
Added popup-div to bannermenu. |
120 |
<div id="popup"></div> |
121 |
|
|
122 |
</div><!-- End of bannerWrapper --> |
|
|
90.1.1
by a11emmjo
Fixed the bannermenu so it shouldn't interfer with the content below. |
123 |
|
|
67.1.2
by a11emmjo
Changed from html to php and with that added some functions to the bannermenu. |
124 |
</div><!-- End of bannerBody --> |
125 |