Chapter 12. Reducing Image Load Times
Images often account for most of the load time of a page. Improving the way images are loaded and reducing the number and size of the images can have a dramatic effect on page load times.
In this chapter, we'll see:
How to make better use of the browser cache, so that images are retained on the browser instead of being loaded repeatedly.
How to reduce overhead in image requests by serving images from a cookieless domain.
How to reduce overall image load times by loading more images in parallel. To make it easy to implement these techniques on your site, they have been implemented in an image adapter, which you'll find in the code bundle you download.
How to reduce the file size of images.
How to reduce the number of images by combining them or by replacing them with HTML and CSS.
Let's start with storing images in the browser cache.
Caching
You can ask the visitor's browser to cache your images on the visitor's machine. This way, the next time they are needed...