Extension:NamespacePaths

NamespacePaths extends custom article paths to allow namespaces to be mapped to extra paths separate from the article path. For example mapping the help namespace to /help/$1 so pages like Help:Contents go to /help/Contents.

Note that NamespacePaths requires hooks introduced in MediaWiki which as of writing is still alpha, for now if you want to use on a production wiki you can try to apply the changes made in to your version of MediaWiki and you won't have to re-patch when you upgrade to 1.19.

The NamespacePaths extension is rather simple, you can copy the important functional pieces of the code into your LocalSettings.php and use it as a base on how to add extra article paths to your wiki.

Installation

 * 1) Download a snapshot and extract it to your extensions directory.  Choose the version that matches your version of MediaWiki.
 * 2) Add   to the bottom of LocalSettings.php.
 * 3) Configure the $wgNamespacePaths with the paths you want to use for namespaces, the key is the namespace id (you can use the NS_ constants), and the value is a $wgArticlePath style string like "/help/$1".
 * 4) Configure your webserver to pass the extra paths to MediaWiki. Consult the short url documentation you set the article paths for your wiki and extend it to map the extra paths to index.php.
 * 5) * Note that you don't want to try mapping things to /index.php?title=$1, doing so will break the paths. If you just make sure that /index.php is run for these extra article paths as long as your webserver sets REQUEST_URI correctly the extension will take it from there and extract the correct title on it's own.
 * 6) Installation can now be verified through Special:Version of your wiki.