* (bug 3806) Gracefully fall back to client-side scaling on |thumb| image

that passes $wgMaxImageArea
This commit is contained in:
Brion Vibber 2005-10-28 00:04:30 +00:00
parent 3bf3fb7c9b
commit 1e4303ef17
2 changed files with 7 additions and 1 deletions

View file

@ -178,6 +178,8 @@ fully support the editing toolbar, but was found to be too confusing.
* Fix Special:BrokenRedirects on MySQL 5.0
* (bug 3807) Fix 'all' in namespaces drop-down on contribs, rc
* Fail gracefully on invalid namespace in Special:Newpages
* (bug 3806) Gracefully fall back to client-side scaling on |thumb| image
that passes $wgMaxImageArea
=== Caveats ===

View file

@ -531,7 +531,11 @@ class Linker {
$textalign = $wgContLang->isRTL() ? ' style="text-align:right"' : '';
$s = "<div class=\"thumb t{$align}\"><div style=\"width:{$oboxwidth}px;\">";
if ( $thumbUrl == '' ) {
if( $thumbUrl == '' ) {
// Couldn't generate thumbnail? Scale the image client-side.
$thumbUrl = $url;
}
if( !$img->exists() ) {
$s .= $this->makeBrokenImageLinkObj( $img->getTitle() );
$zoomicon = '';
} else {