<?php
int sleep ( int $seconds )
where,
$seconds = Number of seconds to delay the program execution
?>
<?php
$lang = 'jp';
$str_tzg = date_default_timezone_get();
$pt = 'Fuso horário atual:<br>';
$en = 'Current Time Zone:<br>';
$jp = 'タイムゾーンセット:<br>';
echo '<br>' . $$lang . ' ' . $str_tzg . '<br><br>';
echo date("l F d Y H:i:s");
echo '<br><br>';
$time2sleep = 15;
sleep($time2sleep);
// Delays the execution time by 15 seconds
echo date("l F d Y H:i:s");
?>
<?php
$lang = 'en';
$str_tzg = date_default_timezone_get();
$pt = 'Fuso horário atual:<br>';
$en = 'Current Time Zone:<br>';
$jp = 'タイムゾーンセット:<br>';
echo '<br>' . $$lang . ' ' . $str_tzg . '<br><br>';
echo date("l F d Y H:i:s");
echo '<br><br>';
$time2sleep = -5;
// Number of seconds less than zero
// This generates Warning in PHP 7.4.XX
// and Fatal error in PHP 8.0.XX
sleep($time2sleep);
echo date("l F d Y H:i:s");
?>