使用计时器php创建一个函数

Hi I want to create a function with a timer that each 5 minutes calls to other function in php. Could someone help me to do this ?

Any kind of information as libraries or similar things is welcome.

ok i tried this: { $tiempo = calcTotalTime($h,$m);

do { $segactuales = microtime('true'); //devuelve los segundos que han pasado desde 1-1-1970 $minutosactuales=(int)($segactuales/60);

if ($minutosactuales==$tiempo)
{
  $count++;
  echo "<br>" . $count;
}

}while($count<=$c); }

but i think i need javascript because if not i get the serverd dead untill the bucle finishes

I think that i know how to do it maybe like this

<?php
$time_start = microtime(true);

// Dormir por un momento
usleep(100);

$time_end = microtime(true);
$time = $time_end - $time_start;

echo "No se hizo nada en $time segundos
";
?>

and if time is a 5 minutes multiple it will call the function. I'll try and now i comement