#15646 [Ana->Bgs]: the flush() does not flush the output buffer

From: Date: Fri, 30 Aug 2002 17:58:43 +0000
Subject: #15646 [Ana->Bgs]: the flush() does not flush the output buffer
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-18275@lists.php.net to get a copy of this message
ID: 15646 Updated by: iliaa@php.net Reported By: kewl@compfort.pl -Status: Analyzed +Status: Bogus Bug Type: Output Control Operating System: Windows 2000 SP2 PHP Version: 4.1.1 New Comment: Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php On both Windows & Linux if output buffering is turned of the echo output will be flushed to screen every time flush() is called. If you do have output buffering enabled and you want to flush the buffer you should use ob_flush(). Previous Comments: ------------------------------------------------------------------------ [2002-04-18 15:47:02] norny@yahoo.com I don't think this is a bug, although I do think bug #16676 is a bug. The default configuration of php.ini automatically buffers 4k of output whether you called ob_start() in the script or not. Since you only have 5 bytes of output, it'll fit well within the 4k of default buffering. Instead of using plain flush(), use ob_flush(), ob_end_flush() at the start of your script, or change the amount of default buffering in your php.ini. If ob_implicit_flush() worked right, you could use it just once at the beginning of your script. See bug #16676 for discoveries with ob. ------------------------------------------------------------------------ [2002-02-25 03:13:51] kewl@compfort.pl Well, I dont think its a browser nor http server issue - I do not use any of these (as I wrote in the original post), only the command-line version. regards, ------------------------------------------------------------------------ [2002-02-24 11:44:37] nohn@php.net well..another thing... I have the same problem... but it's the same server (apache 1.3.23, php 4.1.1 on linux). the problem occurs in ms ie, but not in nn4 or or mozilla. so maybe it's a browser issue ------------------------------------------------------------------------ [2002-02-24 11:43:02] nohn@php.net well..another thing... I have the same problem... but it's the same server (apache 1.3.23, php 4.1.1 on linux). the problem occurs in ms ie, but not in nn4 or or mozilla. so maybe it's a browser issue ------------------------------------------------------------------------ [2002-02-24 05:55:53] yohgaki@php.net flush feature is needed to be fixed ;) If you really need to flush, do not use output buffering. (Without output buffering, PHP always outputs immediately when output is issued) ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/15646 -- Edit this bug report at http://bugs.php.net/?id=15646&edit=1

« previous php.bugs (#18275) next »