transparent PNG thumbnails to white instead of default black. This will
be shown in Internet Explorer 6 and will generally be less invasive
(particularly for black-on-transparent line art!)
Fix for [ 978664 ] Thumbnails of transparent PNGs bad in IE6
if ( (! file_exists( $thumbPath ) ) || ( filemtime($thumbPath) < filemtime($this->imagePath) ) ) {
if ( $wgUseImageMagick ) {
# use ImageMagick
+ # Specify white background color, will be used for transparent images
+ # in Internet Explorer/Windows instead of default black.
$cmd = $wgImageMagickConvertCommand .
- " -quality 85 -geometry {$width} ".
+ " -quality 85 -background white -geometry {$width} ".
escapeshellarg($this->imagePath) . " " .
escapeshellarg($thumbPath);
$conv = shell_exec( $cmd );