PHP output text before sleep

前端 未结 6 1935
走了就别回头了
走了就别回头了 2020-12-02 00:36

I want PHP to output some text, then sleep for a second and a half, and then output some more text.



        
6条回答
  •  情深已故
    2020-12-02 00:49

    echo 'Output one.';
    ob_flush(); 
    flush();
    usleep(1500000);
    echo 'Output two.';
    

提交回复
热议问题