How do I access the ratchet php periodic loop and client sending inside app?
I have a Ratchet server and chat app class which runs fine. My problem is how do I add a periodic loop? I tried to follow the example in Periodically sending mesages to clients in Ratchet But I have been getting nowhere. My goal like this guy, is for the server to check all clients are still alive. Everytime I try to use the addPeriodicTimer, I cant seem to access the $clients public property in chat.php like the guy from the link above could in order to send messages from the timer in server.php. The foreach loop in the periodic timer in server.php keeps complaining that it apparently has an