#20015 [Com]: session.auto_start diables flushing output

From: Date: Tue, 22 Oct 2002 16:03:39 +0000
Subject: #20015 [Com]: session.auto_start diables flushing output
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-23045@lists.php.net to get a copy of this message
ID: 20015 Comment by: amir@abiri-e.com Reported By: amir@abiri-e.com Status: Won\'t fix Bug Type: Output Control Operating System: Linux Redhat 7.2 PHP Version: 4.2.3 New Comment: So this is indeed a bug ? Great. In the meanwhile, for anyone else who is expiriencing the same problem I recommand the solution I found for myself, until more light is shed on this issue. When you configure before the compilation, use the --with-config-file-path=[path] switch, and compile the apache module with let's say /etc/php/apxs/ and the cli binary with /etc/php/cli/. That way you can tweak the configuration independently for each build, and disable things for the cli without interfering with the web server's work. Previous Comments: ------------------------------------------------------------------------ [2002-10-22 03:43:58] yohgaki@php.net Attempt that enables output buffers flushing is rejected, so it won't fix. ------------------------------------------------------------------------ [2002-10-22 01:37:52] sniper@php.net Please try using this CVS snapshot: http://snaps.php.net/php4-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-latest.zip ------------------------------------------------------------------------ [2002-10-21 16:21:07] amir@abiri-e.com also setting "-d session.auto_start=0" in the binary command line in the first line of the script doesn't solve the problem, yet doing so when calling the script in the "php [script name]" form from the shell does. in both cases setting the entry in the ini file solves the problem completely. ------------------------------------------------------------------------ [2002-10-21 16:13:23] amir@abiri-e.com I'm not sure this is indeed a bug, I tried looking for some piece of documentation about this, but failed. I wrote a script that used the flush() command and it failed to operate correctly. knowing the many possible pitfalls around output buffering, and since the role of the script is a web-crawler anyway, I moved it to the cli version, yet the problem persisted - the script (which is meant to work for hours) refuses to flush it's output, no matter what I did. After going over the ini file line by line commenting and uncommenting, I found that "session.auto_start = 1" causes php to fail any form of output buffer flushing: flush(), ob_flush() and implicit_flush directive, even with the cli sapi. I don't want to duplicate the ini file, therefore I would be happy to find a way to keep the apache module with session.auto_start=1, yet overcoming this issue, so to be able to flush my output, at least in cli scripts. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=20015&edit=1

« previous php.bugs (#23045) next »