[Mediawiki-l] Redirect to index.php/Main_Page invalidates url

Platonides Platonides at gmail.com
Wed Feb 3 21:46:54 UTC 2010


Philipp Lies wrote:
>> That would be $wgServer, although if it's not there mediawiki will guess it.
> And unfortunately it guessed wrong.
> 
> Further, I set $wgServer in LocalSettings.php which fixed the redirecting problem for the main page but some parts of MediaWiki seem to ignore this variable.
> $wgServer='http://www.###.com/team1'
> 
> When I load the website and look at the source:
> var stylepath = "/mediawiki/skins";
> var wgArticlePath = "/mediawiki/index.php/$1";
> var wgScriptPath = "/mediawiki";
> var wgScript = "/mediawiki/index.php";
> var wgServer = "http://www.###.com/team1";

Don't embed the path in the server name.
$wgServer='http://www.###.com';
$wgScriptPath='/team1/mediawiki';


> but neither the style is loaded nor the links work, they point to
> http://www.###.com/mediawiki/. 
> Why?

It's using root relative urls.



> I cannot alter $wgScriptPath to "/team1/mediawiki" and $wgServer to "http://www.###.com" as this will break the system:
> "The page isn't redirecting properly"

What is it redirecting to?
You should try to fix this last error. Seems that mediawiki is seeing
itself in a different path.




More information about the MediaWiki-l mailing list