PHP's apache_setenv function causes 500 Internal Server Error

Posted by guitar- on Stack Overflow See other posts from Stack Overflow or by guitar-
Published on 2010-04-18T23:36:33Z Indexed on 2010/04/18 23:43 UTC
Read the original article Hit count: 374

Filed under:
|
|
apache_setenv ( 'no-gzip', 1 )

I'm trying to disable gzip for a certain page's output, but only that page. This works fine on testing servers, but not the production server, which is running the same thing (CentOS and Apache), works on Ubuntu though.

Anyway, do you know why? Or is there some other alternative?

I was thinking of using ob_start () to put all output in a buffer, and then unzip it myself with a PHP function then call ob_end_flush ()... or would it not be gzipped until right before Apache sends it to the client?

Thanks for any help.

© Stack Overflow or respective owner

Related posts about php

Related posts about 500-error