WHAT’S IN THIS CHAPTER?
- Understanding how HTTP compression works
- Becoming familiar with browser quirks and how to handle clients that don’t support compression
- Exploring alternatives to gzip and deflate compression
- Compressing directly in PHP
With bandwidth being a bottleneck for many users (and for dial-up users, easily the largest bottleneck), it’s not surprising that web masters would want to compress their content. The benefits are obvious — faster loading times for users and reduced data transfer bills for web masters. This chapter examines the available methods of compression, which browsers support them, and situations in which compression is not appropriate.
WHO USES COMPRESSION
As you can see, compression is well supported. Of the top 1,000 sites, 227 did not support compression, with only 1 in the top 20 (live.com) and 10 in the top 100 not supporting it.
There’s also a fairly wide range in the amount of compression achieved in this Top 20 table, with the size of the compressed contents being anything between 15 percent and 60 percent of the original. In general, you should expect to see a compression ...