From: webmaster at ex-centris dot com Operating system: RedHat Enterprise Linux 3 PHP version: 5.0.2 PHP Bug Type: Zlib Related Bug description: Content-Encoding header is not set
Description: ------------ I enabled automatic gzip compression with the following line in php.ini: zlib.output_compression = on The problem is that the Content-Encoding header does not get set at all in the response. Therefore, a browser that advertises itself as supporting gzip compression (Accept-Encoding: gzip,deflate) receives compressed content but does not know it is compressed. If I manually add the following to my script: header("Content-Encoding: gzip"); ... it then works. This was tried in the Safari and Firefox clients on Mac OS X. Server is RedHat Enterprise Linux 3 running kernel 2.4.21-20. PHP 5.0.2 running as a module of Apache2 2.0.46. If you need other details do not hesitate to contact me. Thank you. P.S. Even though I compiled PHP with: ./configure --with-apxs2 --with-mysql --with-zlib if I call phpinfo, here what it shows: ./configure --with-apxs2 --with-mysql Reproduce code: --------------- <?php print 'Here is some output !!!'; ?> Expected result: ---------------- Here is some output !!! Actual result: -------------- ??H-JU?,V(??MU?/-)(-QPTT???D?M -- Edit bug report at http://bugs.php.net/?id=30507&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=30507&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=30507&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=30507&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=30507&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=30507&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=30507&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=30507&r=needscript Try newer version: http://bugs.php.net/fix.php?id=30507&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=30507&r=support Expected behavior: http://bugs.php.net/fix.php?id=30507&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=30507&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=30507&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=30507&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=30507&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=30507&r=dst IIS Stability: http://bugs.php.net/fix.php?id=30507&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=30507&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=30507&r=float MySQL Configuration Error: http://bugs.php.net/fix.php?id=30507&r=mysqlcfg