Skip to content

Instantly share code, notes, and snippets.

@samuell
Created October 29, 2012 08:50
Show Gist options
  • Save samuell/3972455 to your computer and use it in GitHub Desktop.
Save samuell/3972455 to your computer and use it in GitHub Desktop.
vhost and php config for clean URLs for mediawiki in a subfolder
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^wiki/(.*)$ /subfolder/w/index.php?title=$1 [L,QSA]
RewriteRule ^$/subfolder/wiki/ [L,QSA]
<?php
$wgScriptPath = "/subfolder/w";
$wgScriptExtension = ".php";
$wgArticlePath = "/subfolder/wiki/$1";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment