Manual:Short URL/Repeated directory errors
From MediaWiki.org
[edit] Repeated directory errors
Should you receive looping alias/rewrite errors such as: 'Cannot find page www.example.com/wiki/wiki/wiki/wiki/wiki/ [...] /index.php' check that $wgserver does not contain any over-lapping path with the $wgScriptpath, $wgScript and $wgArticlePath. The following is an example of what should NOT be done:
#This is an example of what NOT to do! $wgServer = "http://www.example.com/wiki"; $wgServername = "www.example.com/wiki"; $wgScriptpath = "/w";
Because both of the first two variables end in "/wiki" the result will be that the 'Alias /index.php /filesystem/path/to/my/site/index.php' line in httpd.conf will instead redirect ANY index.php file on your whole site to the broken looping alias stated above. Ensure that the $wgServer does not contain any of the contents of the variables mentioned above.
Known working setup based on the above, presuming that you have renamed 'wiki' to 'w' on your server: /wiki
[edit] /var/www/w/LocalSettings.php
$wgServer = "http://www.example.com"; $wgServername = "www.example.com/wiki"; $wgScriptPath = "/w"; $wgScript = "$wgScriptPath/index.php"; $wgArticlePath = "/wiki/$1";
Note: The location of the web root can vary - it might not be /var/www
[edit] httpd.conf
#Put these lines AT THE BOTTOM and IN THIS ORDER Alias /wiki /var/www/w/index.php Alias /index.php /var/www/w/index.php
Note: Windows tends to prefer quotes around paths for aliases, even if there are no spaces. If your web root is not /var/www THIS NEEDS TO BE CHANGED

