-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
45 lines (40 loc) · 942 Bytes
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
require_once 'common-include.php';
$eventRecords = $repository->getEventRecords();
?>
<html>
<head>
<link rel="stylesheet" type="text/css" href="common.css">
<link media="screen" rel="stylesheet" type="text/css" href="browser.css">
<link media="handheld, only screen and (max-device-width: 480px)" href="mobile.css" type="text/css" rel="stylesheet" />
</head>
<body>
<div class="page-content">
<h1>Events</h1>
<?php
require_once 'message-include.php';
if ( count($eventRecords) == 0 ) {
?>
<p>There are no events currently</p>
<?php
}
else {
?>
<ul>
<?php
foreach ( $eventRecords as $eventRecord ) {
?>
<li><a href="event-page.php?event=<?=$eventRecord['id']?>"><?= htmlspecialchars($eventRecord['name'])?></a></li>
<?php
}
?>
</ul>
<?php
}
?>
<div class="bottom-links">
<a href="create-event-page.php">Create event</a>
</div>
</div>
</body>
</html>