Media Wiki Configure Site Logo

From NovaOrdis Knowledge Base
Revision as of 05:54, 18 November 2021 by Ovidiu (talk | contribs) (→‎Overview)
Jump to navigation Jump to search

External

Internal

Overview

Add to LocalSettings.php:

$wgLogos = [
	'1x' => "resources/assets/cat.png",		// path to 1x version
	'1.5x' => "path/to/1.5x_version.png",	// path to 1.5x version
	'2x' => "path/to/2x_version.png",		// path to 2x version
	'svg' => "path/to/svg_version.svg",		// path to svg version
	'icon' => "path/to/icon.png",			// A version of the logo without wordmark and tagline
	'wordmark' => [
		'src' => "path/to/wordmark_version.png",	// path to wordmark version
		'1x' => "path/to/wordmark_version.svg",		// optional if you want to support browsers with SVG support with an SVG logo.
		'width' => 135,
		'height' => 20,
	],
	'tagline' => [
		'src' => "path/to/tagline_version.png",		// path to tagline version
		'width' => 135,
		'height' => 15,
	],
];

The value should be a relative path from DOCUMENT_ROOT.

⚠️ Do not simply overwrite the default logo installed with MediaWiki (/resources/assets/wiki.png); this file will automatically be overwritten when you upgrade and your changes will be lost.