October 17th, 2007 | |
Posted in PHP
Like many other people, I found Mike Lopez’s image thumbnail script quite useful. He has taken the time to go through the brain-crunching algorithm to create image proportional image thumbnails when given a max height/width. Although this script is very handy, it was lacking in a few areas, such as transparent PNG and GIF support, as well as the un-needed resize if the image was smaller than the requested dimensions. I hope I have “helped” in this situation by modifying the script so that it handles such requests. Credit for the transparency support goes to Martin Schmidt (icheee).
One modification I made that is important to note is that the image is now fed through with the SRC variable, rather than the IMG variable. Thanks Mike for this script and I hope my updates really help.
More »