Page 1 of 1

Output buffering / Gzip !?!

Posted: Wed Feb 19, 2003 3:16 pm
by RedDragon
Welli read some page about Gzip and output buffering and tried to integrate gzip into my code

if its not using gzip its just compressing it without gzip...
my questions:
1) Will this code do the job (compress the output) ?
2) Why does ob_end_clean or ob_clean doesnt work when html output is finished (result is a white page), can i use end_flush instead ?
3) Does anyone know about the browser_supports_gzip function as i wasnt able to find anything about it

Code: Select all

/*header.php*/
if($settings['gzip'] == "on" && @browser_supports_gzip && @function_exists('ob_gzhandler')) {
	ob_start('ob_gzhandler');
} else {
	ob_start();
}

//html between

/*footer.php*/
ob_end_flush();
thx for ur help

Posted: Thu Feb 20, 2003 6:56 am
by RedDragon
anyone???