PHP Socket Server – Running as Daemon and Multiple Connections

Code Courtesy: lars at opdenkamp dot eu A socket server written in PHP. This can accept multiple connections and runs as a daemon. pcntl_fork() is thing here that is making this all possible. <?php /** * Listens for requests and forks on each connection */ $__server_listening = true; //error_reporting(E_ALL); set_time_limit(0); ob_implicit_flush(); declare(ticks = 1); become_daemon();… Continue reading PHP Socket Server – Running as Daemon and Multiple Connections