Quote:
Originally Posted by paulius
This works great for me!
As a little note... I found a way to remove the statistics message at the footer of each page by removing the following lines of code in the plugin:
Code:
$output = str_replace('</body>', '<center><span class="smallfont">[Output: ' . $page_kilobyte . ' Kb. compressed to <b>' . $pagenew_kilobyte . '</b> Kb. by saving <b>' . $pagesaved_kilobyte . '</b> Kb. (' . $pagesaved_perc . '%)]</span></center></body>', $output);
Cheers and great plugin! I hope that you improve it to make it even more powerful!
|
I think that you also can remove
Code:
$pagenew_byte=strlen($output);
$page_kilobyte=number_format(($page_byte/1024),2);
$pagenew_kilobyte=number_format(($pagenew_byte/1024),2);
$pagesaved_byte=$page_byte-$pagenew_byte;
$pagesaved_kilobyte=number_format((($pagesaved_byte)/1024),2);
$pagesaved_perc=number_format(((100*$pagesaved_byte)/$page_byte),2);
and leave only
Code:
$page_byte=strlen($output);
$output=preg_replace ('/\r\n(\s*)/', "\r\n", $output);