Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Feb 2007
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    automatic photo resize from thumbnail to larger size

    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

  • #2
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,860
    Thanks
    22
    Thanked 157 Times in 148 Posts
    I wouldn;t use Javascript to do this, I would use PHP's image functions 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...
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :-)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!
    ♪♪ …Need Web Hosting For My YouTube-To-Mp3 Conversion Software? Check Here !!… ♪♪


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •