I'm trying to setup a wiki to use short urls with the following directory structure:
Apache DocumentRoot: /var/www/html
Mediawiki stuff is in /var/www/wiki, this includes index.php, extensions, images, etc.
I can get short URLS to semi-work using the following set up:
mediawiki.conf:
Alias /wiki/skins /usr/share/mediawiki/skins
Alias /wiki /var/www/wiki
<Directory "/var/www/wiki">
LogLevel trace8
SetEnv MW_INSTALL_PATH "/var/www/wiki"
AllowOverride All
Require all granted
Options FollowSymLinks
RewriteEngine On
# This checks to make sure the connection is not already HTTPS
RewriteRule ^(.*)$ index.php?title=$1 [PT,L,QSA]
RewriteRule ^/*$ index.php [L,QSA]
</Directory>
In LocalSettings.php I added:
$wgArticlePath = "/wiki/$1";
Now all links in the wiki omit the index.php?title= part and the rewrite rules seem to work. But the wiki only shows the bare html now, if that makes sense. The skin and the wiki logo are not being used now.
I've also tried using
$wgUsePathInfo = true;
but that doesn't change the outcome.
Does anyone know how to fix this?