matthew tucker
11-28-2003, 04:41 AM
Has anyone worked out how to generate a real resized image thumbnail on the fly using PHP and the GD library? I can't find a hack for it.
In other words, not just displaying the image in a resized <img> tage, but displaying a real re-sized image?
I can do it from an image FILE read directly from an images folder, but I can't work out how to pass the data from $attachment(filedata) to the ImageCreateFromJPEG ($imgfile) function. Just replacing $imgfile with $attachment(filedata) doesn't work of course.
The top image in the left hand column at the following website is done from a file in a folder.
http://www.screeneditors.com/forums/index.php
the other images in the left hand column are just resized. Modem users complaining a bit ...
is there a better way than saving the imagedata in a temp file then processing it?
In other words, not just displaying the image in a resized <img> tage, but displaying a real re-sized image?
I can do it from an image FILE read directly from an images folder, but I can't work out how to pass the data from $attachment(filedata) to the ImageCreateFromJPEG ($imgfile) function. Just replacing $imgfile with $attachment(filedata) doesn't work of course.
The top image in the left hand column at the following website is done from a file in a folder.
http://www.screeneditors.com/forums/index.php
the other images in the left hand column are just resized. Modem users complaining a bit ...
is there a better way than saving the imagedata in a temp file then processing it?