summaryrefslogtreecommitdiffstats
path: root/blog.php
diff options
context:
space:
mode:
authorSquibid <me@zacharyscheiman.com>2023-09-26 16:55:27 -0400
committerSquibid <me@zacharyscheiman.com>2023-09-26 16:55:27 -0400
commit13561786a746131091e791187d4793432d2984ad (patch)
tree5a70b65ef22a11617c85e83f0700d7cf2373cbdb /blog.php
parent48475ae4abd6c7103a1871235a4fcab5dc1b6177 (diff)
downloadsite-13561786a746131091e791187d4793432d2984ad.tar.gz
site-13561786a746131091e791187d4793432d2984ad.tar.bz2
site-13561786a746131091e791187d4793432d2984ad.zip
Big changes!
- Fixed typo in pinned git repos - Add new pinned repo (wallheaven) - Switch blog generation to php - remove useless symlink in blog/
Diffstat (limited to 'blog.php')
-rw-r--r--blog.php46
1 files changed, 46 insertions, 0 deletions
diff --git a/blog.php b/blog.php
new file mode 100644
index 0000000..bcf1767
--- /dev/null
+++ b/blog.php
@@ -0,0 +1,46 @@
+<!DOCTYPE HTML>
+<html lang="en">
+ <head>
+ <title>Squibid's Blog</title>
+ <link rel="stylesheet" href="style.css">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
+ </head>
+ <style type="text/css">
+ #bloglist {
+ text-align: left;
+ font-size: 2ch;
+ }
+ p#bloglist span {
+ float: right;
+ color: white;
+ }
+ </style>
+ <body style="background-color: #161617;">
+ <div id="master">
+ <header>
+ <h1 id="font", style="margin-bottom: 0">
+ <a href="https://squi.bid">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"] : "¯\_(ツ)_/¯");
+ }
+ }
+ ?>
+ </p>
+ <h2 id="font" style="text-align: center; margin-top: 0;">
+ <a href="/blog/rss.xml", title="rss">subscribe</a>
+ </h2>
+ </div>
+ </body>
+</html>