forked from team/site
1
0
Fork 0

fix accessibility warning

This commit is contained in:
Ben Harris 2021-03-29 11:57:03 -04:00
parent 61369c7ecc
commit de9c94f339
1 changed files with 8 additions and 6 deletions

View File

@ -33,16 +33,18 @@ if (!isset($_GET["page"]) || !file_exists("pages/{$_GET['page']}.md")) {
</p>
<hr>
<h3>pages:</h3>
<h2>pages:</h2>
<?php
foreach (glob("pages/*.md") as $page) {
<ul>
<?php foreach (glob("pages/*.md") as $page) {
$yaml = $parser->parse(file_get_contents($page))->getYAML();
if (!$yaml["published"]) continue; ?>
<a href="<?=basename($page, ".md")?>"><?=$yaml["title"]?></a><br>
<?php }
<li><a href="<?=basename($page, ".md")?>"><?=$yaml["title"]?></a></li>
<?php } ?>
</ul>
} else {
<?php } else {
$pg = $parser->parse(file_get_contents("pages/{$_GET["page"]}.md"));
$yml = $pg->getYAML();