Personal website written in PHP, using Smarty for templates, and a lot of home-made CSS.
For a development environment you must have the following installed;
- nginx
- PHP 8.x
- php-fpm
- composer (see)
- copy
.env.example
to.env
and replace the proper variable with your own (likeWEB_ROOT
with where you cloned this repo.) - copy
nginx.conf
to where your nginx configs go (and replacekate.pet
with whatever domain you wish) and make sure thatfastcgi_pass
is using the correct socket location. - make sure you install dependencies with
composer install
and you should be set :3
- when adding a blog post, make sure that there is a
.md
file with the same name as the.php
file in./blog_posts/
- this is because
retrieveBlogPost($postId)
fetches the content by fetching a file with the same name as thepostId
provided but with the extension of.md
instead of.php
- this is because
- when fetching stuff from the GET parameters (in
$_REQUEST
), make sure to sanitize with thebasename
function