Yngvarr

Generation

generate functionSat, 07 Jan 2023

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;

Questions about programming?Chat with your personal AI assistant