RE: [PHP] Output Buffering and zlib Compression Issue
| From: | Jan Reiter | Date: | Sat, 04 Aug 2007 00:03:52 +0000 |
| Subject: | RE: [PHP] Output Buffering and zlib Compression Issue | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-260168@lists.php.net to get a copy of this message | ||
Hi!
I'm not quite sure what you are trying to do ...
Why do you use output buffering in your code, when you turn it off in the
htaccess directive??
php_flag output_buffering Off
The code worked for me. But I tested it without your htaccess settings ....
Jan
-----Ursprüngliche Nachricht-----
Von: Chris [mailto:chris@dented-planet.net]
Gesendet: Samstag, 4. August 2007 01:18
An: php-general@lists.php.net
Betreff: [PHP] Output Buffering and zlib Compression Issue
When I run the following code (PHP 5.2.2, 5.2.3) via Apache (with an
htaccess file), I get this error:
Notice: ob_end_clean() [ref.outcontrol]: failed to delete buffer zlib
output compression. in ...
Can anyone explain what's going on?
I'm assuming it isn't a bug and I've read the documentation. Did I
miss something?
htaccess file code:
php_flag output_buffering Off
php_flag zlib.output_compression On
php_value zlib.output_compression_level "-1"
PHP Code:
<?php
error_reporting(E_ALL | E_NOTICE);
ini_set('display_errors', '1');
ob_start();
echo "You shouldn't see this.";
while (ob_get_level() > 0) {
ob_end_clean();
}
ob_start();
echo "You SHOULD see this.";
ob_end_flush();
?>
Chris
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php