1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15:
function getmicrotime(){ list($usec, $sec) = explode(" ",microtime()); return ((float)$usec + (float)$sec); } $time_start = getmicrotime(); # DEIN CODE. $time_end = getmicrotime(); $time = $time_end - $time_start; $time = number_format($time,3,',','.'); echo $time;