How to make progress bar with jQuery and PHP while waiting server process?

后端 未结 2 2048
予麋鹿
予麋鹿 2021-01-18 23:53

It used to be easy to find solutions of my problem when Google gives many accurate results that point to Stackoverflow. But, I didn\'t found one for this problem. If any of

2条回答
  •  长发绾君心
    2021-01-19 00:17

    You can output javascript from your long running script:

    while(doThings()) {
        echo '
    ';
        flush();
    }
    

    I personaly use bootstrap: http://getbootstrap.com/components/#progress

提交回复
热议问题