...

View Full Version : automatic photo resize from thumbnail to larger size



angelica
02-10-2007, 11:52 PM
What is the best way to build a web page that will automatically resize a 400x500(or whatever) photo to a thumbnail version in my html page?

I want to be able to upload only one file to the ftp site and not 2. Here is a diagram to better explain what I am after.

http://home.cogeco.ca/~newbie/images/photo-gallery.gif

Thanks

chump2877
02-11-2007, 12:13 AM
I wouldn;t use Javascript to do this, I would use PHP's image functions (http://us3.php.net/manual/en/ref.image.php) to dynamically resample your images and reproduce them at a smaller size...

Especially if you have a lot of thumbnails on one page, this will drastically reduce loading times of your pages....

However, if you only have a thumbnail or two per page (and your not worried about page load time), I suppose you could just use a little math, either JS or PHP (doesn;t matter which one), and CSS to resize your images...In this case, though, your full sized images will still need to be loaded to the page, after which the images can be resized...



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum