Syncronise Server Seconds with JS Clients
- by imperium2335
I would like to drive a setTimeout loop based on the time of the server, seconds only.
So when the seconds on the server is 30, some function is run on all clients. It is vital that they do not become totally out of sync with the server, as there will be a CRON job running on the server every, say, 45 seconds which is important to the system functioning correctly.
It is ok if a client is out by a few seconds with the server, client do not need to be synced to each other.
I am using Jquery library.
Hope this makes sense!