Extension:Icon

From MediaWiki.org
Jump to: navigation, search
MediaWiki extensions manual - list
Crystal Clear action run.png
Icon

Release status: stable

Implementation Parser extension
Description Allows using images as icons (linkless and linked both supported)
Author(s) Tim LaquaTalk
Last version 1.6.1 (2009-08-31)
MediaWiki 1.10+
License No license specified
Download Download snapshot
Subversion [Help]

Browse source code
View code changes

Check usage (experimental)
Bugs: list open list all report

Extension is based on the ImageLink and ImageMap extensions - removes dependencies, allows for linkless icons, and also implements MW thumbnailing functionality. Is quite a bit lighter & quicker than ImageMap if all you want is an icon.

  • Supports linkless images and linked images
  • Intended to simplify use of uploaded images as icons
  • Utilizes MW thumbnailing rather than having the browser resize the image - renders MUCH higher quality icons and loads only the thumbnail sized image, yielding faster client-side page render times.
  • ALT text is populated in both the ALT and TITLE attributes of the IMG tag for tooltip functionality

[edit] Installation

  1. Create a new folder (directory) in the following location:
    wiki-install-folder/extensions/Icon
  2. Download the following required files:
  3. Copy the files in to the new Icon folder
  4. Add the following code to your LocalSettings.php (at the bottom)
require_once( "$IP/extensions/Icon/Icon.php" );

[edit] Usage

  1. Follow Installation Instructions
  2. You will have a new Parser Function (#icon) - Syntax is as follows:
 {{#icon: image title | image alt text | image width | page to link to }}
  • Only the image title argument is required - the rest are optional.
 {{#icon: Info.png|Info}} will display the Info.png icon in its default size
 {{#icon: Info.png|Info|24}} will display the Info.png icon with a width of 24px
 {{#icon: Info.png|Info|24|Special:Help}} same as above and clicking on it will link to Special:Help
Personal tools
Namespaces
Variants
Actions
Site
Support
Download
Development
Communication
Print/export
Toolbox