-
Notifications
You must be signed in to change notification settings - Fork 4
/
index.php
40 lines (38 loc) · 1.2 KB
/
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>DB Slides</title>
<link href="./lib/fontawesome.all.min.css" rel="stylesheet">
<link rel="icon" href="favicon.ico" type="image/x-icon">
</head>
<body>
<h1>Slides</h1>
<?php
$files = glob('./*.{html}', GLOB_BRACE);
foreach($files as $file) {
echo "<a href=\"$file\">$file</a> <a href=\"$file?print-pdf&showNotes=true\"><i class=\"fas fa-print\"></i></a> <a href=\"$file?2V\">2V</a> <a href=\"$file?2V&print-pdf&showNotes=true\"><i class=\"fas fa-print\"></i></a><br>";
}
?>
<hr>
<h1 onClick="javascript:document.querySelector('#exams').style.visibility = document.querySelector('#exams').style.visibility == 'hidden' ? 'visible' : 'hidden';">Exercise Sheets</h1>
<?php
$files = glob('./exercises/*.{html}', GLOB_BRACE);
foreach($files as $file) {
echo "<a href=\"$file\">$file</a><br>";
}
?>
<hr>
<div id="exams" style="visibility:hidden">
<h1>Exams</h1>
<?php
$files = glob('./exams/*.{html}', GLOB_BRACE);
foreach($files as $file) {
echo "<a href=\"$file\">$file</a><br>";
}
?>
</div>
</body>
</html>