PHP code example of cxj / php-interval-timers
1. Go to this page and download the library: Download cxj/php-interval-timers library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
cxj / php-interval-timers example snippets
er = new Cxj\Timers;
$name = "sample timer";
$timer->start($name);
usleep(1000);
$r1 = $timer->read($name);
echo "$r1 seconds have passed since timer was started" . PHP_EOL;