Topic on Project:Support desk

Setting logo path ($wgLogo) in LocalSettings.php

3
Sorrel (talkcontribs)

I'm trying to set a custom logo by setting $wgLogo in LocalSettings.php:

$wgLogo = "{$wgUploadPath}/d/d4/Logo.png";

per https://www.mediawiki.org/wiki/Manual:FAQ#How_do_I_change_the_logo.3F

However, this doesn't seem to work; the path to the logo ends up being just /d/d4/Logo.png, presumably because $wgUploadPath is false when LocalSettings.php is executed, and only gets set to a useful value when Setup.php runs. What's the "correct" way to set the path to the logo as an uploaded file?

MediaWiki 1.28.0, PHP 5.6, MariaDB 10.1

MarkAHershberger (talkcontribs)

Try

$wgLogo = "{$wgScriptPath}/images/d/d4/Logo.png";

Or, try setting $wgUploadPath to the path to your images directory.

Sorrel (talkcontribs)

Setting $wgUploadPath to "$wgScriptPath/images" worked, thanks!