Manual:$wgEnableAutoRotation

From MediaWiki.org
Jump to: navigation, search
Images: $wgEnableAutoRotation
Whether to enable image auto-rotation based on Exif information
Introduced in version: 1.18.0 (r99910)
Removed in version: still in use
Allowed values: boolean
Default value: true if the image rasterizer supports rotation, false otherwise

Other settings: Alphabetical | By Function


Usage [edit]

To explicitly disable Image auto-rotation add to the bottom of LocalSettings.php

$wgEnableAutoRotation = false;

Explicitly setting to true is probably a bad idea (Since if the image render-er supports rotation, it should be auto-detected).

Details [edit]

If it is true, MediaWiki will look at the Exif Orientation metadata field (Which is set by digital cameras when pictures are taken sideways) and automatically rotate the image to the correct rotation.

If not set in LocalSettings.php (or if set to null) then this setting takes its value from BitmapHandler::canRotate() method - which returns true if the image rendering method supports rotation.

Warning Warning: After changing this setting, if you have images that appear squished (width and height are reversed) you may have to run the maintenance script: php refreshImageMetadata.php --force --quiet
You can use ?action=purge on image pages to update scaled images (thumbnails, etc) after changing this.
Language: English