Blog

Me, my life, my interests

Serving mediawiki from a subdomain

I just managed to get MediaWiki working from a subdomain, rather than from /wiki. There are two changes that you need to make to localsettings.php when trying to serve MediaWiki from a subdomain. The first is to change

$wgScriptPath = "" ;

from whatever the path was, and the second is to insert:

$wgServer = "http://subdomain.yourdomain.tld";

The first setting stops the scripts from being called from the wiki subdirectory (which is now your subdomain) and the second tells bits of MediaWiki where to find things like the skins and images. That's the best explanation I can come up with right now!

Reference Installing MediaWiki on a subdomain and Serving MediaWiki from a Subdomain