MySQL Forums
Forum List  »  PHP

Re: Using images with php and sql
Posted by: Rick James
Date: October 27, 2011 07:30AM

Hyperlinked, tool-tipped, image:
    <a href=for_more_info.php title="red striped jumper">
        <img src=images/red_jumper.jpg>
        Buy this dashing garment
    </a>
You can reference multiple images (above) in a single <html> file.

> Will I have to create a new file for EVERY image I use??
Eh? Yes, each image will be its own file (eg images/red_jumper.jpg).

(Suggested, but not required: Put all the images in a separate directory, as I did with "images/".)

If you are doing both thumbnails and full-sized images, recommend you build both images, with slightly different filenames (such as prepending 't' for the thumbnails).

Sure, it is possible to use height= and width= in <img> to shrink the full image to thumbnail size, but it costly for the user -- his browser has to download the full image, then shrink it.

Options: ReplyQuote


Subject
Written By
Posted
October 23, 2011 11:17PM
Re: Using images with php and sql
October 27, 2011 07:30AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.