dcsimg
Login | Register   
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.


advertisement
 

Optimizing the HTML Code : Page 4

You can do some simple things with your HTML tags to make graphics feel faster and work better for all readers.


advertisement

WEBINAR:

On-Demand

Application Security Testing: An Integral Part of DevOps


Don't Resize the Image
Use the image at its actual size.

Yes, you can use the width and height image tag attributes to shrink or enlarge an image on-the-fly, but all that does is add processing time for your readers.

Instead, use the image at the size you have saved it in your graphics program. And if you need to use it at a different size, resize it with your image editing tool.

Original size = 252 x 144 pixels
IMG attributes width="252" height="144"
File size = 10.1K
Original size = 252 x 144 pixels
IMG attributes width="121" height="69"
File size = 10.1K
Image had to download, then the browser needed to resize it.
Original size = 121 x 69 pixels
IMG attributes width="121" height="69"
File size = 3.3K
Smaller file, faster download and no resizing.




Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
Thanks for your registration, follow us on our social networks to keep up-to-date