summaryrefslogtreecommitdiffstats
path: root/blog.php
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--blog.php (renamed from blog.html)17
1 files changed, 12 insertions, 5 deletions
diff --git a/blog.html b/blog.php
index f9cd986..bcf1767 100644
--- a/blog.html
+++ b/blog.php
@@ -25,11 +25,18 @@
</header>
<hr style="color: #f7f7f7;">
<p id="bloglist">
- <!-- b script marker blog -->
-<a href="/blog/librex-and-dots"> librex and dots</a><span>2023/06/27</span><br>
-<a href="/blog/It's-Alive!"> It's Alive!</a><span>2023/05/01</span><br>
-<a href="/blog/state-of-the-site"> state of the site</a><span>2023/03/11</span><br>
- <!-- e script marker blog -->
+ <?php
+ $path = "blog";
+ $files = scandir($path."/");
+ foreach ($files as $file) {
+ if (preg_match("/.+?(?=\.html|\.php)/", $file, $matches)) {
+ $tags = get_meta_tags($path.'/'.$file);
+ printf('<a href='.$path.'/%s>%s</a><span>%s</span><br>',
+ $matches[0], str_replace("-", " ", $matches[0]),
+ $tags["date"] ? $tags["date"] : "¯\_(ツ)_/¯");
+ }
+ }
+ ?>
</p>
<h2 id="font" style="text-align: center; margin-top: 0;">
<a href="/blog/rss.xml", title="rss">subscribe</a>