How to add image with link in a sidebar - MediaWiki

mediawiki, php

Solution

Three possible approaches:

- Write a custom skin, that handles the sidebar any way you want.

- Write a tiny extension using the hook SkinBuildSidebar, to handle some custom code for images

- Use `MediaWiki:Common.js` to modify the sidebar using javascript.

I would without doubt go for 2.

edit: Note that some skins might ignore the SkinBuildSidebar hook. As long as you have no custom skins enabled, you should be fine, though.

Problem

I can add links to a MediaWiki sidebar this way: ``` * some-url|url-text ``` But how can i add image instead of text without hacking core or standard templates? I have read this: http://www.mediawiki.org/wiki/Manual_talk:Interface/Sidebar#Images_in_the_navigation_bar But it's just a feature request.

Original source