summaryrefslogtreecommitdiffstats
path: root/blog/index.php
diff options
context:
space:
mode:
authorSquibid <me@zacharyscheiman.com>2023-10-30 12:47:55 -0400
committerSquibid <me@zacharyscheiman.com>2023-10-30 12:47:55 -0400
commit1bc1454b9312e4322d486437055408d1ff35fb22 (patch)
tree98b270badb82304f520414c35ac8d6b25d7ea466 /blog/index.php
parent2d90cc615120fcc892c1b22a2d00578b1c486c72 (diff)
downloadsite-1bc1454b9312e4322d486437055408d1ff35fb22.tar.gz
site-1bc1454b9312e4322d486437055408d1ff35fb22.tar.bz2
site-1bc1454b9312e4322d486437055408d1ff35fb22.zip
New blog entry and changes to how blogs are displayed
- blogs are now in subdirs - blog list is generated through helper function - full blog list is in blog subdir
Diffstat (limited to '')
-rw-r--r--blog/index.php (renamed from blog.php)15
1 files changed, 2 insertions, 13 deletions
diff --git a/blog.php b/blog/index.php
index bcf1767..d60a42d 100644
--- a/blog.php
+++ b/blog/index.php
@@ -20,23 +20,12 @@
<div id="master">
<header>
<h1 id="font", style="margin-bottom: 0">
- <a href="https://squi.bid">Squibid's</a> Blog
+ <a href="/">Squibid's</a> Blog
</h1>
</header>
<hr style="color: #f7f7f7;">
<p id="bloglist">
- <?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"] : "¯\_(ツ)_/¯");
- }
- }
- ?>
+ <?php include(__DIR__.'/../misc/tools.php'); entries("../blog"); ?>
</p>
<h2 id="font" style="text-align: center; margin-top: 0;">
<a href="/blog/rss.xml", title="rss">subscribe</a>