Can closing the browser terminate the PHP script on the server?

后端 未结 4 1569
無奈伤痛
無奈伤痛 2020-12-05 18:50

Say a user clicked a button, which resulted in a jquery ajax request being sent to my server.

The server begins a complicated process in response to the ajax request

4条回答
  •  忘掉有多难
    2020-12-05 19:26

    Unless it's launched as a background process i.e. with the & at the end... it will just terminate.

    Closing browser a bit more to it... It will stop eventually, but will process for a little while before web server realises connection is gone.

提交回复
热议问题