USLEEP(3) 1 USLEEP(3)
usleep - Delay execution in microseconds
SYNOPSIS
void usleep (int $micro_seconds)
DESCRIPTION
Delays program execution for the given number of microseconds.
PARAMETERS
o $micro_seconds
- Halt time in microseconds. A microsecond is one millionth of a second.
RETURN VALUES
No value is returned.
EXAMPLES
Example #1
usleep(3) example
<?php
// Current time
echo date('h:i:s') . "
";
// wait for 2 seconds
usleep(2000000);
// back!
echo date('h:i:s') . "
";
?>
The above example will output:
11:13:28
11:13:30
SEE ALSO
sleep(3), time_nanosleep(3), time_sleep_until(3), set_time_limit(3).
PHP Documentation Group USLEEP(3)