From: Derk-Jan Hartman Date: Sun, 20 Feb 2011 21:31:15 +0000 (+0000) Subject: Gallery's perrow was overwriting the original style= attribute. X-Git-Tag: 1.31.0-rc.0~31848 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/categories/modifier.php?a=commitdiff_plain;h=73ad3337dd14e31e3c08ac64cebc46acb154865b;p=lhc%2Fweb%2Fwiklou.git Gallery's perrow was overwriting the original style= attribute. --- diff --git a/includes/ImageGallery.php b/includes/ImageGallery.php index 7290e5918e..aa25c37f0b 100644 --- a/includes/ImageGallery.php +++ b/includes/ImageGallery.php @@ -227,7 +227,8 @@ class ImageGallery if ( $this->mPerRow > 0 ) { $maxwidth = $this->mPerRow * ( $this->mWidths + 50 ); - $this->mAttribs['style'] = "max-width: {$maxwidth}px;_width: {$maxwidth}px;"; + $oldStyle = isset( $this->mAttribs['style'] ) ? $this->mAttribs['style'] : ""; + $this->mAttribs['style'] = "max-width: {$maxwidth}px;_width: {$maxwidth}px;" . $oldStyle; } $attribs = Sanitizer::mergeAttributes(