In doing a comet function, the second request is a request to get information, the program has been blocked
Code:
Then the third request is a request that triggers a condition in HTML and then initiates
What is the reason that the third request will not be executed until the execution of the second request is completed?
In doing PHP comet function encountered this problem a good pit dad ....
What's the problem?
Reply content:
In doing a comet function, the second request is a request to get information, the program has been blocked
Code:
Then the third request is a request that triggers a condition in HTML and then initiates
What is the reason that the third request will not be executed until the execution of the second request is completed?
In doing PHP comet function encountered this problem a good pit dad ....
What's the problem?
Take a look at the timeline, the third request should be a wait-out state (Blocking), and the second request is completed before it is issued from the browser
This is generally because the previous request returned connection:keep-alive, but the response was not completed
Subsequent homologous requests will wait until the TCP link is released by the previous request and becomes available
http://leeon.me/a/persistent-link-poll-ajax-requests-with-php
Self-answer ... Come across this question and see this article