Alex Trofimov 8 лет назад
Родитель
Сommit
dc56a7c943
1 измененных файлов с 8 добавлено и 0 удалено
  1. 8 0
      inc/utils.inc.php

+ 8 - 0
inc/utils.inc.php

@@ -497,6 +497,14 @@ function echoDbgLog($mWhat, $sDesc = '', $sFileName = 'debug.log')
     fclose($rFile);
 }
 
+function dbgTiming($sStartMicrotime)
+{
+    $i1 = explode(' ', microtime ());
+    $i2 = explode(' ', $sStartMicrotime);
+    $iTime = ($i1[0]+$i1[1]) - ($i2[0]+$i2[1]);
+    return round($iTime, 3) . ' sec';
+}
+
 function echoJson($a)
 {
 	header('Content-type: text/html; charset=utf-8');