summaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
author53hornet <atc@53hor.net>2021-12-11 12:20:12 -0500
committer53hornet <atc@53hor.net>2021-12-11 12:20:12 -0500
commit69631b42fae57ecf1fd84271421152035535980f (patch)
tree02569d1b6049d6cba1568988564a46209156c024 /index.php
parent00d6a7d10f6267e437b330aa99df091bfc7c67b6 (diff)
download53hor-69631b42fae57ecf1fd84271421152035535980f.tar.xz
53hor-69631b42fae57ecf1fd84271421152035535980f.zip
fix: posts not rendering
Diffstat (limited to 'index.php')
-rw-r--r--index.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/index.php b/index.php
index bb6cfa9..5e5e92d 100644
--- a/index.php
+++ b/index.php
@@ -3,8 +3,8 @@ include('./includes/head.php');
$page = strtok($_SERVER['REQUEST_URI'], '/');
-if (!empty($page) && $page == "posts" && ($post = strtok('/')) && !empty($post)) {
- include("./posts/$post.php");
+if (!empty($page) && $page[0] >= '0' && $page[0] <= '9') {
+ include("./posts/$page.php");
} else if (!empty($page)) {
include("./pages/$page.php");
} else {