-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathminutes.php
46 lines (46 loc) · 1.76 KB
/
minutes.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
46
<?php
require "header.php";
?>
<p>This page lists the agendas and minutes from RCSA open meetings.</p>
<div class="panel-group" id="accordion">
<?php
$json = json_decode(file_get_contents("data/meetings.json"), true);
if ($json) {
$first = key($json);
foreach ($json as $year => $meetings) {
?>
<div class="panel panel-default">
<div class="panel-heading">
<h4 class="panel-title">
<a data-toggle="collapse" data-parent="#accordion" href="#<?php echo $year?>"><?php echo $year?></a>
</h4>
</div>
<div id="<?php echo $year?>" class="list-group panel-collapse collapse <?php echo ($year == $first) ? "in" : ""?>">
<?php
foreach ($meetings as $isodate => $contents) {
$date = date('jS F Y', strtotime($isodate));
echo "<span class=\"list-group-item\">$date<br/>";
foreach ($contents as $thing => $desc) {
if ($thing === "Minutes") {
echo "<a href=\"/files/meetings/minutes_$isodate.pdf\"><span class=\"glyphicon glyphicon-download\" aria-hidden=\"true\"></span> Minutes</a> ";
} else if ($thing === "Agenda") {
echo "<a href=\"/files/meetings/agenda_$isodate.pdf\"><span class=\"glyphicon glyphicon-download\" aria-hidden=\"true\"></span> Agenda</a> ";
} else if ($thing === "Comments") {
echo "($desc)";
} else {
echo "<a href=\"/files/meetings/$desc\"><span class=\"glyphicon glyphicon-download\" aria-hidden=\"true\"></span> $thing</a> ";
}
}
echo "</span>\n";
}
?>
</div>
</div>
<?php
}
} else {
echo "<p>Error reading meeting information</p>";
}
?>
</div>
<?php require "footer.php"?>