Sunday, May 22, 2005, 08:40 PM CET
I just implemented on-the-fly gzip compression here. It was fairly easy, since my (Perl) script uses HTML::Template, so all I had to do—after checking if the client supports gzip, via the Accept-Encoding HTTP header—was find a way to zip the return value of $template->output(). Compress::Zlib::memGzip() gets the job done and it’s about a third faster than invoking gzip. Yay.