php-ify things
continuous-integration/drone/push Build is passing Details

This commit is contained in:
leah 2021-04-13 00:40:44 +01:00
parent f7fba54e95
commit e45b7c476c
3 changed files with 17 additions and 13 deletions

View File

@ -29,7 +29,12 @@
<hr class="zig"> <hr class="zig">
<hr class="zag"> <hr class="zag">
<h3>latest memo</h3> <h3>latest memo</h3>
<?php include('memos/latest.html'); ?> <?php
$dir = './memos/memos/';
$scanned_directory = array_diff(scandir($dir), array('..', '.'));
$target_file = $dir.max($scanned_directory);
include $target_file;
?>
<a href="/memos/">see more</a> <a href="/memos/">see more</a>
<hr class="zig"> <hr class="zig">
<hr class="zag"> <hr class="zag">

View File

@ -3,7 +3,9 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>memos - south london</title> <title>memos - south london</title>
<link rel="stylesheet" href="./main.css"> <link rel="stylesheet" href="/memos/main.css">
<link rel="stylesheet" href="/memos/fonts.css">
</head> </head>
<body> <body>
<header> <header>
@ -11,13 +13,13 @@
<h1>memos</h1> <h1>memos</h1>
</header> </header>
<main> <main>
<div class="memo" id="1"> <?php
<h2>memos</h2> foreach (glob("memos/*.html") as $filename)
<p> {
hello, this is where any news will go. subscribe to rss if you're interested! include $filename;
</p> }
<em class="attr">~cark - 12/04/2021</em> ?>
</div>
</main> </main>
<footer><a href="./memos.rss">rss</a></footer> <footer><a href="./memos.rss">rss</a></footer>
</body> </body>

View File

@ -1,7 +1,4 @@
<link rel="stylesheet" href="/memos/fonts.css"> <div class="memo" id="01">
<link rel="stylesheet" href="/memos.css">
<div class="memo" id="1">
<h2>memos</h2> <h2>memos</h2>
<p> <p>
hello, this is where any news will go. subscribe to rss if you're interested! hello, this is where any news will go. subscribe to rss if you're interested!