-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
executable file
·27 lines (27 loc) · 914 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
<HTML>
<Head>
<Title>Ed's Documentation</Title>
<link rel="stylesheet" href="style.css" />
<script src="script.js"></script>
</Head>
<Body>
<div class="control">
Select Document:
<Select id="option" onchange="sendView()">
<option value="blank.md"></option>
<?php
if ($handle = opendir('file')) {
while (false !== ($entry = readdir($handle))) {
if ($entry != "." && $entry != "pub" && $entry != ".." && $entry != "blank.md" && $entry != "README.md" && $entry != ".git") {
$entry_name = rtrim($entry, ".md");
echo "<option id=\"$entry\">$entry_name</option>";
}
}
closedir($handle);
}
?>
</Select>
</div>
<iframe id="viewer" src="file.html?file=file/blank.md"></iframe>
</Body>
</HTML>