diff options
author | 53hornet <atc@53hor.net> | 2021-12-11 11:26:18 -0500 |
---|---|---|
committer | 53hornet <atc@53hor.net> | 2021-12-11 11:26:18 -0500 |
commit | 00d6a7d10f6267e437b330aa99df091bfc7c67b6 (patch) | |
tree | b3ffb8fc4f09933ebc8ed9c90f03412250199dd8 | |
parent | de9bbfdb8f0d3b366e76a5cc775690f7315c740f (diff) | |
download | 53hor-00d6a7d10f6267e437b330aa99df091bfc7c67b6.tar.xz 53hor-00d6a7d10f6267e437b330aa99df091bfc7c67b6.zip |
chore: organize pages and use router/renderer, organize assetsrouting
-rw-r--r-- | assets/53hornet.svg (renamed from 53hornet.svg) | 0 | ||||
-rw-r--r-- | assets/atc.gpg (renamed from contact/atc.gpg) | 0 | ||||
-rw-r--r-- | assets/cv.html (renamed from hireme/cv.html) | 2 | ||||
-rw-r--r-- | assets/cv.php (renamed from hireme/cv.php) | 0 | ||||
-rw-r--r-- | assets/iosevka-slab-regular.woff2 (renamed from includes/iosevka-slab-regular.woff2) | bin | 376848 -> 376848 bytes | |||
-rw-r--r-- | includes/head.php | 4 | ||||
-rw-r--r-- | includes/nav.php | 1 | ||||
-rw-r--r-- | index.php | 6 | ||||
-rw-r--r-- | pages/contact.php (renamed from contact/index.php) | 10 | ||||
-rw-r--r-- | pages/donate.php (renamed from donate/index.php) | 0 | ||||
-rw-r--r-- | pages/hireme.php (renamed from hireme/index.php) | 8 | ||||
-rw-r--r-- | pages/info.php (renamed from info/index.php) | 9 | ||||
-rw-r--r-- | pages/links.php (renamed from links/index.php) | 7 | ||||
-rw-r--r-- | pages/payments.php (renamed from payments/index.php) | 4 | ||||
-rwxr-xr-x | serve.sh | 4 |
15 files changed, 13 insertions, 42 deletions
diff --git a/53hornet.svg b/assets/53hornet.svg index 520d069..520d069 100644 --- a/53hornet.svg +++ b/assets/53hornet.svg diff --git a/contact/atc.gpg b/assets/atc.gpg index d720d81..d720d81 100644 --- a/contact/atc.gpg +++ b/assets/atc.gpg diff --git a/hireme/cv.html b/assets/cv.html index 5c93878..a332f0d 100644 --- a/hireme/cv.html +++ b/assets/cv.html @@ -9,7 +9,7 @@ >git.53hor.net</a > <!--<label for="cv">CV</label> - (<a id="cv" href="https://www.53hor.net/hireme/cv.php">Download a PDF copy</a>)--> + (<a id="cv" href="https://www.53hor.net/assets/cv.php">Download a PDF copy</a>)--> <p> I am a computer programmer who has been developing and maintaining native and diff --git a/hireme/cv.php b/assets/cv.php index c9255a8..c9255a8 100644 --- a/hireme/cv.php +++ b/assets/cv.php diff --git a/includes/iosevka-slab-regular.woff2 b/assets/iosevka-slab-regular.woff2 Binary files differindex fda41e3..fda41e3 100644 --- a/includes/iosevka-slab-regular.woff2 +++ b/assets/iosevka-slab-regular.woff2 diff --git a/includes/head.php b/includes/head.php index 4b95e2f..748e4b7 100644 --- a/includes/head.php +++ b/includes/head.php @@ -15,7 +15,7 @@ @font-face { font-family: "Iosevka Slab"; font-display: swap; - src: url("/includes/iosevka-slab-regular.woff2"); + src: url("/assets/iosevka-slab-regular.woff2"); } :root { @@ -194,7 +194,7 @@ } ?> - <link rel="icon" href="/53hornet.svg" type="image/svg+xml"> + <link rel="icon" href="/assets/53hornet.svg" type="image/svg+xml"> </head> <body> diff --git a/includes/nav.php b/includes/nav.php index de72e9d..03e9c5f 100644 --- a/includes/nav.php +++ b/includes/nav.php @@ -60,3 +60,4 @@ </li> </ul> </nav> +<hr /> @@ -1,8 +1,12 @@ <?php include('./includes/head.php'); -if (($post = strtok($_SERVER['REQUEST_URI'], '/')) && !empty($post)) { +$page = strtok($_SERVER['REQUEST_URI'], '/'); + +if (!empty($page) && $page == "posts" && ($post = strtok('/')) && !empty($post)) { include("./posts/$post.php"); +} else if (!empty($page)) { + include("./pages/$page.php"); } else { include('./includes/render_index.php'); } diff --git a/contact/index.php b/pages/contact.php index 5d1cc76..2d6c7af 100644 --- a/contact/index.php +++ b/pages/contact.php @@ -1,6 +1,3 @@ -<?php -include('../includes/head.php'); -?> <h1>Contact Me</h1> <h2> @@ -13,10 +10,10 @@ include('../includes/head.php'); <pre> <code> # FreeBSD: -$ fetch -o - https://www.53hor.net/contact/atc.gpg | gpg --import +$ fetch -o - https://www.53hor.net/assets/atc.gpg | gpg --import # Also FreeBSD, but more inclusive: -$ curl https://www.53hor.net/contact/atc.gpg | gpg --import +$ curl https://www.53hor.net/assets/atc.gpg | gpg --import </code> </pre> @@ -30,6 +27,3 @@ You may read more in the <a href="https://www.gnupg.org/gph/en/manual/x56.html"> <p> If you want to hire me or have a business inquiry, here is a Google Voice number. Please understand that all calls and text messages are screened for spam by Google before I pick up. </p> -<?php -include('../includes/foot.php'); -?> diff --git a/donate/index.php b/pages/donate.php index 82fbd8a..82fbd8a 100644 --- a/donate/index.php +++ b/pages/donate.php diff --git a/hireme/index.php b/pages/hireme.php index e366e32..5073d56 100644 --- a/hireme/index.php +++ b/pages/hireme.php @@ -1,6 +1,3 @@ -<?php -include('../includes/head.php'); -?> <h1 style="text-align: center;">Carpenter Tech</h1> <p> @@ -36,12 +33,9 @@ include('../includes/head.php'); <hr /> <?php -include('cv.html'); +include('./assets/cv.html'); ?> <p> <img src="https://nextcloud.53hor.net/index.php/s/zL2AJHwtCWLX2Eq/preview" /> </p> -<?php -include('../includes/foot.php'); -?> diff --git a/info/index.php b/pages/info.php index a2ca53b..d3a1b4c 100644 --- a/info/index.php +++ b/pages/info.php @@ -1,6 +1,3 @@ -<?php -include('../includes/head.php'); -?> <h1>Info</h1> <p> @@ -88,12 +85,8 @@ include('../includes/head.php'); <img style="border: 0; width: 88px; height: 31px" src="https://jigsaw.w3.org/css-validator/images/vcss-blue" alt="Valid CSS!" /> -<img src="https://nextcloud.53hor.net/index.php/s/JMqd6ACCdskmS5J/preview" width="graphic-width-in-pixels" height="graphic-height-in-pixels" alt="Viewable With Any Browser" /> +<img src="https://nextcloud.53hor.net/index.php/s/JMqd6ACCdskmS5J/preview" alt="Viewable With Any Browser" /> <a href="https://validator.w3.org/feed/check.cgi?url=https%3A//www.53hor.net/feed.php"><img src="https://nextcloud.53hor.net/index.php/s/Ly6CBibnCFA99Fz/preview" alt="[Valid RSS]" title="Validate my RSS feed" /></a> <img src="https://nextcloud.53hor.net/index.php/s/nKmSsrxa4LkRHdM/preview" /> - -<?php -include('../includes/foot.php'); -?> diff --git a/links/index.php b/pages/links.php index 3012a69..6c75b67 100644 --- a/links/index.php +++ b/pages/links.php @@ -1,6 +1,3 @@ -<?php -include('../includes/head.php'); -?> <h1>Egress Links</h1> <p> @@ -14,7 +11,3 @@ include('../includes/head.php'); <ul> <li><a href="https://docs.freebsd.org/en/books/handbook/">FreeBSD Handbook</a></li> </ul> - -<?php -include('../includes/foot.php'); -?> diff --git a/payments/index.php b/pages/payments.php index cb6c58f..4315613 100644 --- a/payments/index.php +++ b/pages/payments.php @@ -1,7 +1,3 @@ -<?php -include('./includes/head.php'); -?> - <!--PAYPAL--> <div id="smart-button-container" class="form"> <p id="invoiceidError" class="description">Please enter an Invoice ID</p> diff --git a/serve.sh b/serve.sh deleted file mode 100755 index 007e036..0000000 --- a/serve.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -php -S localhost:8000 & -[ -n "$1" ] && firefox "localhost:8000/$1" & -wait |