setVariable() and getVariable() can be used from both the parent- and the child process to share variables. To observe the alive status, the child process should call _setAlive() in a frequent interval, so that the parent process can check the last alive time via getLastAlive() . To get the PID of the child process, the parent can call getPid() .
Don't forget that a web application doesn't have to be written completely in one language.
There is an approach that called 'problem picks the language'.
Since PHP is not initially built for such things, you can use other languages for your multi-processing tasks.