use strict; use Compress::Zlib; print "Content-type: text/html\n"; print "Content-encoding: gzip\n\n"; my $ausgabe = "hallo"; print Compress::Zlib::memGzip($ausgabe);