| Versions | |
|---|---|
| 4.7 – 7 | timer_start($name) |
Start the timer with the specified name. If you start and stop the same timer multiple times, the measured intervals will be accumulated.
name The name of the timer.
drupal/
<?php
function timer_start($name) {
global $timers;
$timers[$name]['start'] = microtime(TRUE);
$timers[$name]['count'] = isset($timers[$name]['count']) ? ++$timers[$name]['count'] : 1;
}
?>