- Install PHP
- Install sqlite3 (probably already installed)
- Install PDO Sqlite extension for you php version
PHP has a built-in web server.
php -S localhost:8080
will serve the current directory on that url.
php -S localhost:8080 -t public
For rewrite rules, you can point the command to a specific router file:
php -S localhost:8080 -t public router.php
This router.php is found at the php.net website:
<?php
if (preg_match('/\.(?:png|jpg|jpeg|gif|css|js)$/', $_SERVER["REQUEST_URI"])) {
return false;
} else {
include __DIR__ . '/index.php';
}