Manual:Image thumbnailing

MediaWiki's extended image syntax allows images to be automatically thumbnailed (see Configuring file uploads for general help on file uploads).

Bitmaps
Image thumbnailing requires either ImageMagick or GD library. ImageMagick is recommended since it produces better quality thumbnails than GD library. It can be downloaded from imagemagick.org. Neither of these are part of the default MediaWiki installation but MediaWiki can be installed without this function.

To enable image thumbnailing, set $wgUseImageResize and $wgUseImageMagick to true in LocalSettings.php. Make sure the $wgImageMagickConvertCommand variable points to the proper location of the convert command of your installation and that the command is executable by the web server process.

SVG
MediaWiki supports SVG image rendering: if enabled, SVG images can be used like other image files; they will automatically be rendered as a PNG file on demand. To enable SVG support:

First, allow upload of SVG files in the LocalSettings.php file: $wgFileExtensions[] = 'svg'; Note that MediaWiki will refuse SVG files containing JavaScript, for security reasons. To avoid some false positives, set $wgAllowTitlesInSVG = true;. If you get an error saying the file is corrupt, make sure mime type detection is working properly.

Second, set $wgSVGConverter to the renderer you want to use. Available options are ImageMagick, sodipodi, inkscape, batik, and rsvg. The default is ImageMagick, but it is recommended to use one of the other renderers if possible. If the converter program is not in the system path, you have to specify the directory that contains the program using $wgSVGConverterPath.