Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <head>
- <meta charset="UTF-8">
- <title>Loop</title>
- <?php //https://stackoverflow.com/questions/10144780/how-do-echo-out-progress-on-mamp-using-flush/10145076#10145076
- ob_start();
- ob_implicit_flush(true);
- set_time_limit(0);
- $buffer = str_repeat(".", 16384);
- echo $buffer."\r\n<br />\r\n";
- for ($i=0; $i<20; $i++) {
- echo ($i+1).""."\r\n<br />\r\n".$buffer."\r\n<br />\r\n";
- ob_flush();
- flush();
- //sleep(1);
- usleep(500000);
- }
- ob_end_flush();
- ?>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment