in reply to Re: STDOUT and mod_perl
in thread STDOUT and mod_perl

This is not exactly what I want, and I've already looked at these things. I am not looking to compress all the output in response to the request from the browser. I am looking to have my CGI give output as either 'gzipped' or as 'text' depending on an option selected by the user. If selected, I want the output to come as an file attachment.

-a

Replies are listed 'Best First'.
Re^3: STDOUT and mod_perl
by Anonymous Monk on Aug 29, 2006 at 14:40 UTC
    Look a little harder, CGI::Compress::Gzip works with mod_perl:
    Note that the Zlib library on which this code is ultimately based requires a fileno for the output filehandle. Where the output filehandle is faked (i.e. in mod_perl), we instead use in-memory compression. This is more wasteful of RAM, but it is the only solution I've found (and it is one shared by the Apache::* compression modules).