summaryrefslogtreecommitdiffstats
path: root/index.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 /index.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 '')
-rw-r--r--index.php (renamed from index.html)25
1 files changed, 21 insertions, 4 deletions
diff --git a/index.html b/index.php
index c650d46..6c47c76 100644
--- a/index.html
+++ b/index.php
@@ -38,9 +38,13 @@
</hgroup>
<p>My best repos are</p>
<ul>
+ <li><a href="https://git.squi.bid/wallheaven">Wallheaven</a> -
+ A private frontend for wallhaven written in
+ <a href="https://php.net">php</a>!
+ </li>
<li><a href="https://git.squi.bid/eat-it">eat it</a> -
Eat It is a <a href="https://mpv.io", title="Mpv's Website">Mpv</a>
- package manager writter in <a href="https://lua.org",
+ package manager written in <a href="https://lua.org",
title="Lua's Website">Lua</a> with the intent of making Mpv
scripts easier to update and use.</li>
<li><a href="https://git.squi.bid/coreutils">coreutils</a> -
@@ -60,9 +64,22 @@
</p>
</hgroup>
<p id="blogpreview">
- <!-- b script marker blog -->
- If this is here I forgot to generate the blog list.
- <!-- e script marker blog -->
+ <?php
+ $path = "blog";
+ $files = scandir($path."/");
+ $i = 0;
+ foreach ($files as $file) {
+ if (preg_match("/.+?(?=\.html|\.php)/", $file, $matches)) {
+ if ($i > 4)
+ break;
+ $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"] : "¯\_(ツ)_/¯");
+ $i++;
+ }
+ }
+ ?>
</p>
<a href="/blog">more...</a>
</div>