Forums / Developer / How to minify html / Comment65875
Marko Žmak
Monday 14 February 2011 4:12:12 am
I have modified the HTML.php library to take two more options in the $options parameter:
and created an output filter that uses it. It works OK for now.
The difference is 152Kb to 100KB, so I save 52KB per page, not bad. With limitLineLengths turned ON, I get the same so I think I'll leave it.
I have also made a template operator so only some parts of the html can be minified.
And I found a little bug in HTML.php, it doesn't remove multiple whitespaces between two pieces of simple text, for example, a string like "aaaa bbb" will remain untact.
As for the mod_pagespeed I found out that is rather unstable and it can be a performance and security risk to install it. So we should forget about it for now.
-- Nothing is impossible. Not if you can imagine it! Hubert Farnsworth