..


Sponsored Links

Sleep

The sleep function is used to delay the execution of a script.
This function accepts a single parameter (numerical value integer) that represents the number of seconds you want to delay the execution. For example:

 



 <? Php







 / / Current time







 echo date ('h: i: s').

 



 "<br/>";









 / / Suspend execution for 10 seconds







 Sleep (10);









 / / Current time stamp again







 echo date ('h: i: s');







 ?>

 
The result is returned to me when I write is:





 11:42:21







 11:42:31



See also usleep (delay the execution of a script in milliseconds)

In the same category ...
E-Learning
Linux (Course) Linux (Course)
Complete guide to open-source system. From 49 €.
MySQL (Course) MySQL (Course)
Management of open-source database. From 39 €.
PHP (Course) PHP (Course)
Full course for creating dynamic Web sites. From 49 €.
Sponsored Links