Compress-LeadingBlankSpaces

 view release on metacpan or  search on metacpan

LeadingBlankSpaces.pm  view on Meta::CPAN


=head1 DESCRIPTION

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, the browser ignores all leading blank spaces.
Indeed, the amount of those blank spaces is significant
and could be estimated as 10 to 20 percent of the length of regular web page.
We can reduce this part of the web traffic on busy servers
with no visible impact on transferred web content. This could be helpful
especially for old browsers incapable to understand modern content compression.

The main functionality of this class is concentrated within the C<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 to serve possible exceptions, like pre-formatted data within HTML.

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

E<lt>CODE ...E<gt> ... E<lt>/CODEE<gt>

README  view on Meta::CPAN


=head1 DESCRIPTION

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 C<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:



( run in 0.248 second using v1.01-cache-2.11-cpan-87723dcf8b7 )