Does PHP provide a function to sleep in milliseconds?
Right now, I'm doing something similar to this, as a workaround.
$ms = 10000;
$seconds = round($ms / 1000, 2);
sleep($seconds);
I'd like to know whether there is a more generic function that is available in PHP to do this, or a better way of handling this.
time_nanosleep()
andtime_sleep_until()
are other sleep functions, but I don't see them as being viable alternatives. – Latinist