views:

689

answers:

10

What is the nest PHP thumbnailer/resizer class that preferably works on most shared hosts?

Clarification: I'm looking for a PHP class/wrapper (eg. phpThumb(), Asido), so I don't have to run GD or ImageMagick functions directly. I'm specifically looking for resizing and framing functions.

A: 

GD is supported on many hosts http://uk3.php.net/manual/en/book.image.php

Fire Lancer
A: 

I guess the best two (and by far the most common) are either GD or ImageMagick. I've had a lot of joy with the second.

Sklivvz
A: 

Imagick is a native PHP extension to create and modify images using the ImageMagick API. It is used on many shared hosts:

http://pecl.php.net/package/imagick

Espo
A: 

Imagemagick is good, and has two APIs for PHP:

http://www.imagemagick.org/script/api.php#php

http://www.imagemagick.org/script/api.php#php

Geoffrey Chetwood
A: 

I've found that both ImageMagick and GD are too slow for creating un-cacheable dynamic images on the fly if you have more than one request per second. I had to serve dozens of requests per second, and found that I could get around 50 times speed improvement by writing the routine as FastCGI with C & jpeglib.

Bemmu
not the answer that i'm looking for, but certainly good information! ;)
xtimesninety
+2  A: 

I have good experiences with both phpThumb and Wideimage. Wideimage is the more modern PHP5 approach while phpThumb has much more features.

Mathias
thanks! it's the first time i heard of wideimage ;) i'll check it out
xtimesninety
btw i've had some problems when I use phpThumb on some shared hosts
xtimesninety
A: 

I use Greg_Photo as an accessor to the underlying GD commands. For pretty basic resizing it works great.

dragonmantank
Dude, your link just crashed my chrome (malware alert).
Huppie
A: 

Asido works great with some modifications ;) It supports most features that I need (resizing, framing), has drivers for both GD and Imagemagick, nice simple API, and organized codebase.

xtimesninety
A: 

ImageMagick will definitely produce really sharp images, but it's not easy to install or manage. ImageMagick itself needs to be installed on the server, and then a compatinble version of MagickWand needs to be installed.

I've also found that it has a habit of creating massive temporary files of up to a GB or more and then dumping them into your /tmp directory, which you need to be careful of. It will also eat up a massive amount of memory unpredictably.

For these reasons, I would not recommend ImageMagick if you are on a shared host.

Chris Henry
A: 

Here's a great script with great documentation. http://phpthumb.gxdlabs.com/

Catfish