Home > Article > Backend Development > Recommended articles about the php connection_status() function
PHP actively disconnects from the browser I once compiled an article "In-depth analysis of set_time_limit(), connection_status() and ignore_user_abort() in PHP connection processing", which explains the processing of server PHP scripts when the browser client is disconnected. This article will explain how the server PHP script actively disconnects from the browser. The main method is to use Content-Length and Connection in the http protocol header. The role of Content-Length: After the browser receives the message entity with the specified Content-Length size, it will disconnect from the server. The role of Connection: After the browser receives the Close or Keep-Alive of the Connection, it decides whether to close the connection or continue to use the current connection for the next request. /*** Automatically disconnect from the browser * jiaofuyou */1
1. 10 course recommendations about connection_status
##Introduction: PHP actively disconnects from the browser. I once compiled an article "In-depth analysis of set_time_limit(), connection_status() and ignore_user_abort() in PHP connection processing", which is to explain browsing Processing of server PHP scripts when the server client is disconnected. This article will explain how the server PHP script actively disconnects from the browser. The main method is to use Content-Length and Conne in the http protocol header...
2 . How to use connection_status()? Summary of connection_status() instance usage
##Introduction: PHP actively disconnects from the browser has been sorted An article "In-depth analysis of set_time_limit(), connection_status() and ignore_user_abort() in PHP connection processing" explains the processing of server PHP scripts when the browser client is disconnected. This article will explain how the server PHP script actively disconnects from the browser. The main method is to use the Content-Length in the http protocol header...
##3.
PHP method of detecting whether the user closes the browserIntroduction:: This article mainly introduces the method of PHP detecting whether the user closes the browser. Interested in PHP tutorials? Students can refer to it.
4.
In-depth analysis of set_time_limit, connection_status and ignore_user_abort in PHP connection processingIntroduction::This article It mainly introduces the in-depth analysis of set_time_limit, connection_status and ignore_user_abort in PHP connection processing. Students who are interested in PHP tutorials can refer to it.
5.
php-redis Chinese Reference Manual_Ping_echo_set_get_setex_psetex_..._PHP TutorialIntroduction: php-redis Chinese reference manual_Ping_echo_set_get_setex_psetex_…. ping Description Check the current connection status Check the status of the current connection instance Parameters (none) Return Value STRING: +PONG on success. Throws a RedisException object on co
6.
PHP ignore_user_abort and connection_status and register_shutdown_fu_PHP tutorialIntroduction: PHP ignore_user_abort and connection_status and register_shutdown_fu. PHP ignore_user_abort and connection_status and register_shutdown_function Usage method Use ignore_user_abort() to implement PHP scheduled tasks Syntax: int ignore_user_abort(int [setting]); Return
7.
PHP actively disconnects with Browser connection_PHP tutorialIntroduction: PHP actively disconnects from the browser. PHP actively disconnects from the browser. I once compiled an article "In-depth analysis of set_time_limit(), connection_status() and ignore_user_abort() in PHP connection processing", which is to explain the browser client
8.
PHP miscellaneous functions, php miscellaneous functions_PHP tutorialIntroduction: PHP miscellaneous functions, php miscellaneous functions. PHP Miscellaneous Functions, PHP Miscellaneous Functions Function Description connection_aborted() Checks whether the client is disconnected. connection_status() returns the current connection status. connection_timeout() in PHP4 ##9. Is it necessary to send data to detect the PHP connection status Introduction: Help: Is it necessary to send data to detect PHP connection status? I have an application. After the client submits the calculation, the server starts calculation, waits for about 1 minute, and returns the calculation result. The client exits midway. This requires me to exit the calculation. Question 1: How to detect the status without sending bytes, for example, the following is sent Code for byte detection connection status
How to determine the execution time of the set function
Introduction: How to judge and set function execution time? function a(){ //... return true; } function b(){ //... return false; } Now start calling a(); Imagine that if a() does not return a result after 1.2 seconds, call b() immediately; Is there any beautiful way to deal with it?
The above is the detailed content of Recommended articles about the php connection_status() function. For more information, please follow other related articles on the PHP Chinese website!