获取毫秒级时间戳

public function getMsecTime()
{
  list($msec, $sec) = explode(' ', microtime());
  $msectime = (float)sprintf('%.0f', (floatval($msec) + floatval($sec)) * 1000);
  return $msectime;
 
}

posted @ 2020-12-04 20:43  诸天一根草凡尘一粒沙  阅读(100)  评论(0编辑  收藏  举报