return gz archive
$gz = gzencode($string, 9); $filename = 'compressed.gz'; header("Content-Encoding: gzip"); header("Content-Length: ".strlen($gz)); header("Content-Disposition: attachment; filename=$filename"); header("Content-Type: text/plain"); echo $gz;