O'Reilly logo

Platinum Edition Using XHTML™, XML, and Java™ 2 by Andrew H. Watt, Mike Morgan, Jim O'Donnell, Eric Ladd

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Keeping File Sizes Small

One of the greatest courtesies you can extend to your users is to keep your graphics files small. Invariably, the graphics take the longest time to download. By keeping the file sizes small, you minimize the time that users spend waiting to see your pages. Your typical 30KB to 50KB graphics file might load in a few seconds over a T1 connection, but it might take several minutes for users dialing up with a 28.8Kbps or 14.4Kbps connection.

You can enlist several techniques to help keep your file sizes small:

  • Crop.

  • Make the image dimensions as small as possible.

  • Use thumbnail versions of images.

  • Save GIFs with natural color gradients as JPEGs or PNGs.

  • Increase the amount of JPEG compression.

  • Use fewer bits per pixel to store ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required