Re[2]: [PHP-WIN] sleep() & flush()
| From: | Pablo Vera | Date: | Fri, 25 Aug 2000 14:55:55 +0000 |
| Subject: | Re[2]: [PHP-WIN] sleep() & flush() | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-2151@lists.php.net to get a copy of this message | ||
Klaus, Andrian:
What browsers are you using ?, I know that Netscape and Explorer will
act differently. I am only guessing, but I think that Klaus is using
Netscape and Andrian, Explorer. As I have seen, Netscape will begin
displaying items after the </html> tag is received, but Explorer will
display text and images as soon as they come from the server.
What I'm saying is that the problem is not on the script, but on the
way the browser display things.
Pablo
AP> 1193-639-1 wrote:
>>
>> this snip will not work: nor with 3.0.16 or 4.0.2 dev
>> not online nor local!
>> what's wrong eh?
>> <?
>> $t="This is a silly text!\n<br>";
>> print $t;
>> flush();flush();flush();flush(); //nothing happens! not even you send
>> thausands of flush()
>> sleep(25); //after 25 seconds you'll see both lines
>> at once
>> echo $t;
>> ?>
>>
>> PHP = Paranoid Heuristic Professor?
>>
>> :-)
>> Klaus
AP> It works for me on PHP 4 RC2 on Linux and PHP 3.0.16 on Win 2000 (I
AP> tried a slightly ifferent code, as I didn't have the time to wit 25
AP> seconds :-)
AP> $t="This is a silly text!\n<br>";
AP> print $t;
AP> flush();
AP> sleep(5);
AP> echo $t;
AP> Andrian