ID: 34429 Comment by: fabwash at hotmail dot com Reported By: zimage at icdsoft dot com Status: Open Bug Type: CGI related Operating System: * PHP Version: 5CVS, 4CVS (2005-09-12) New Comment:
I have the same problem.. What I did was to send a lot of blank space to fill up the buffer: add_message($id, str_pad('',4096)); That fixed the problem but increases the bandwidth. Previous Comments: ------------------------------------------------------------------------ [2005-10-10 15:06:16] pdxtechie at gmail dot com This would also be useful for Ajax (using, for example, the RicoAjaxEngine.) If you are unable to disable buffering, there is no way to stream XML for progress updates through Ajax. ------------------------------------------------------------------------ [2005-09-12 16:08:04] zimage at icdsoft dot com It could be also used for writing progress bars. On a random shared hosting server: locate .php |wc -l 25147 locate .php |xargs -n1 -i grep -H -e "flush *(" {} 641 So people are using it for some reason... I can see flush() used in Moveable Type, Word Press, MediaWiki and so on. ------------------------------------------------------------------------ [2005-09-12 15:49:27] [EMAIL PROTECTED] Writing such things using PHP is pretty useless IMO, but if it works with other SAPIs.. ------------------------------------------------------------------------ [2005-09-12 15:47:25] zimage at icdsoft dot com This is how you could write a chat client for example. Connection is kept open for the duration of chat session and php script is looping over the client and server messages. ------------------------------------------------------------------------ [2005-09-10 22:56:11] [EMAIL PROTECTED] How would it be useful to be able to turn it off? ------------------------------------------------------------------------ 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/34429 -- Edit this bug report at http://bugs.php.net/?id=34429&edit=1