About OB output issues
Ob_start ();
echo str_repeat ("", 4098);
for ($i =65; $i <70; $i + +) {
echo Chr ($i);
Ob_flush ();
Flush ();
Sleep (1);
}
?>
Ask the above code in IE,FF is normal, you can output ABCDE in turn, and in Google Browser cannot be displayed sequentially, but once output ABCDE, originally thought is Google cache too big increase str_repeat for 9000 is still an output, do not know what is the reason?
------Solution--------------------
I don't know, 360 what's the speed of the kernel
Originally this kind of output is very boring, previously only know the server-related, and now has a browser-related
Visible success becomes a small probability event.
No practical value, no need to focus on it
------Solution--------------------
if (ob_get_level () = = 0) ob_start ();
for ($i = 0; $i <10; $i + +) {
echo "
Line to show. ";
Echo Str_pad (' 1 ', 4096). " \ n ";
Echo str_repeat ("1", 4098);
Ob_flush ();
Flush ();
Sleep (2);
}
echo "done.";
Ob_end_flush ();