Page MenuHomePhabricator

$wgStylePath does not default to "/wiki/skins/ "
Closed, InvalidPublic

Description

Author: budmaddock

Description:
The default path to $wgLogo appears to be broken at $wgStylePath, referencing "includes/DefaultSettings.php" documentation.
Explicitly adding $wgStylePath = "/wiki/skins/" near the end of LocalSettings.php corrects the problem.

Detailed workaround:
Change LocalSettings.php
$wgStylePath = "/wiki/skins/";
$wgLogo="{$wgStylePath}/common/images/wikidog.png";
Place image in /var/lib/mediawiki/skins/common/images/wikidog.png

According to the documentation the $wgStylePath line is not necessary but the code will not work without it. It would be helpful to know where $wgStylePath points when customizing LocalSetting.php


Version: 1.11.x
Severity: major
OS: Linux
Platform: PC

Details

Reference
bz18650

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:35 PM
bzimport set Reference to bz18650.
bzimport added a subscriber: Unknown Object (MLST).

karun.84 wrote:

Hello,
I am currently having a look at the bug now.
The default value from http://www.mediawiki.org/wiki/Manual:$wgStylePath is "{$wgScriptPath}/skins".
What do you have defined for $wgScriptPath and has this been changing at all within the configuration?

Regards

karun.84 wrote:

Hello,
This problem occurs when $wgScriptPath is changed in the configuration files, as $wgStylePath utilises this as part of the default path being $wgScriptPath/skins. A lot of the paths that are set use $wgScriptPath as the base, and when this is changed the other paths will need to be redefined.

The installation script that comes with MediaWiki will set $wgScriptPath for you when it is installed.

Most of the information about the default values is available in the Manual at http://www.mediawiki.org/wiki/Manual:$wgStylePath