From 51e36e4da267ceed908f2eb0ed8a4886f9951134 Mon Sep 17 00:00:00 2001 From: real_nowhereman Date: Thu, 25 Aug 2011 19:39:13 +0000 Subject: [PATCH] thumb patch (still not working) --- fp-plugins/thumb/plugin.thumb.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fp-plugins/thumb/plugin.thumb.php b/fp-plugins/thumb/plugin.thumb.php index 505709b..ade2a72 100755 --- a/fp-plugins/thumb/plugin.thumb.php +++ b/fp-plugins/thumb/plugin.thumb.php @@ -86,7 +86,6 @@ function plugin_thumb_create($fpath, $infos, $new_width, $new_height) { $scaled = imagecreatetruecolor($new_width, $new_height); - imagecopyresampled($scaled, $image, 0, 0, 0, 0, $new_width, $new_height, $infos[0], $infos[1]); /* * If gif or png preserve the alpha channel * @@ -102,6 +101,8 @@ function plugin_thumb_create($fpath, $infos, $new_width, $new_height) { $output='jpg'; } + imagecopyresampled($scaled, $image, 0, 0, 0, 0, $new_width, $new_height, $infos[0], $infos[1]); + if($output=='png') { imagepng($scaled, $thumbpath); } elseif($output=='gif') {