Forum Moderators: coopster

Message Too Old, No Replies

Sending Compressed Documents in PHP 5.x

ob_gzhandler doesn't seem to work

         

Jeremy_H

9:03 pm on Sep 12, 2006 (gmt 0)

10+ Year Member



I used to use PHP 4.x on my website, but then I upgraded to 5.x.

Since the upgraded, it seems my method of sending out compressed documents of my site no longer works.

Under 4.x, at the top of all my PHP pages, I was able to add the line:

<?php ob_start("ob_gzhandler");?>

How do I send out compressed documents in PHP 5.x?

Thanks

[edited by: Jeremy_H at 9:04 pm (utc) on Sep. 12, 2006]

eelixduppy

9:24 pm on Sep 12, 2006 (gmt 0)




Note: ob_gzhandler() requires the zlib [us3.php.net] extension.

Are you sure you have this extension correctly installed?

Jeremy_H

10:51 pm on Sep 12, 2006 (gmt 0)

10+ Year Member



Thanks for the reply,

I believe so. If I go to phpinfo(); I get:

ZLib Support enabled
Compiled Version 1.1.4
Linked Version 1.1.4

coopster

8:59 pm on Sep 13, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Some related discussions that may help:

GZIP Pro and Downfall [webmasterworld.com]
ob_gzhandler generating garbage with SSI files [webmasterworld.com]
zlib - having problems [webmasterworld.com]
Running ob_start("ob_gzhandler") in windows [webmasterworld.com]