free web stats

Dokuwiki .htaccess File - Sample

So it came about that I setup a wiki, but chose to use dokuwiki rather than mediawiki because it was a flat file system and installed easily. I needed a way to change the ugly urls to fancy SEO'ed ones. I created the .htaccess file, then dropped this in there:

RewriteEngine on

RewriteBase /

RewriteRule ^_media/(.*) lib/exe/fetch.php?media=$1 [QSA,L]
RewriteRule ^_detail/(.*) lib/exe/detail.php?media=$1 [QSA,L]
RewriteRule ^_export/([^/]+)/(.*) doku.php?do=export_$1&id=$2 [QSA,L]
RewriteRule ^$ doku.php [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) doku.php?id=$1 [QSA,L]
RewriteRule ^index.php$ doku.php

back to top