Compress-LeadingBlankSpaces README


Compress-LeadingBlankSpaces documentation  | view source Contained in the Compress-LeadingBlankSpaces distribution.

Index


NAME

Top

Compress::LeadingBlankSpaces - Perl class to compress leading blank spaces in (HTML, JavaScript, etc.) web content.

DESCRIPTION

Top

This class provides the functionality for the most simple web content compression.

Basically, the outgoing web content (HTML, JavaScript, etc.) contains a lot of leading blank spaces, because of being structured on development stage. Usually, browser ignores leading blank spaces. Indeed, the amount of those blank spaces is as significant as 10 to 20 percent of the length of regular web page. We can reduce this part of web traffic on busy servers with no visible impact on transferred web content, especially for old browsers incapable to understand modern content compression.

The main functionality of this class is concentrated within the squeeze_string member function that is supposed to be used inside the data transfer loop on server side. The rest of the class is developed in order to serve possible exceptions, like pre-formatted data within HTML.

In this version of the class, the tags those produce compression exceptions are:

<CODE ...> ... </CODE>

<PRE ...> ... </PRE>

<TEXTAREA ...> ... </TEXTAREA>

All are case insensitive in implementation.

Nesting of exceptions is not allowed.

INSTALLATION

Top

To install this module type the following:

   perl Makefile.PL
   make
   make test
   make install

DEPENDENCIES

Top

This module requires these other modules and libraries:

  Perl 5.004 or higher.

AUTHOR

Top

Slava Bizyayev <slava@cpan.org> - Freelance Software Developer & Consultant.

COPYRIGHT AND LICENSE

Top

SEE ALSO

Top

Web Content Compression FAQ at http://perl.apache.org/docs/tutorials/client/compression/compression.html

Apache::Dynagzip module can be found on CPAN.


Compress-LeadingBlankSpaces documentation  | view source Contained in the Compress-LeadingBlankSpaces distribution.