summaryrefslogtreecommitdiff
path: root/.htaccess
diff options
context:
space:
mode:
authorDaniel Weipert <code@drogueronin.de>2023-11-13 13:37:26 +0100
committerDaniel Weipert <code@drogueronin.de>2023-11-20 17:30:39 +0100
commitd017568a77d677e449e66d689450532a760d6f11 (patch)
tree2d386b94278f30d6fe3dc585e4be3f676b549621 /.htaccess
initial commit
Diffstat (limited to '.htaccess')
-rw-r--r--.htaccess9
1 files changed, 9 insertions, 0 deletions
diff --git a/.htaccess b/.htaccess
new file mode 100644
index 0000000..d025b2b
--- /dev/null
+++ b/.htaccess
@@ -0,0 +1,9 @@
+RewriteEngine On
+# Redirect /index.php to / (optional, but recommended I guess)
+RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /.*index\.php
+RewriteRule ^index.php/?(.*)$ $1 [R=301,L]
+
+# Run everything else but real files through index.php
+RewriteCond %{REQUEST_FILENAME} !-d
+RewriteCond %{REQUEST_FILENAME} !-f
+RewriteRule ^(.*)$ index.php/$1?%{QUERY_STRING} [L]