If you want to test whether processes owned by other users are running, you can use:
<?php
$running=posix_kill($pid, 0);
if(posix_get_last_error()==1) /* EPERM */
$running=true;
?>
If the process is owned by somebody else (and you're not root), you will get an EPERM.
On my system (FreeBSD) this is defined to 1.
You should test what the value of EPERM is on your system.