思绪的空中生活

PHP时间戳精确到毫秒
参考:https://www.jianshu.com/p/ad4a2b502d88<?php functio...
扫描右侧二维码阅读全文
19
2018/03

PHP时间戳精确到毫秒

参考:https://www.jianshu.com/p/ad4a2b502d88

<?php
function microtime_float()
{
    list($usec, $sec) = explode(" ", microtime());
    return ((float)$usec + (float)$sec);
}
$tInt = (int)(microtime(true)*1000);
echo "tInt = $tInt <p>";
Last modification:March 19th, 2018 at 04:58 pm
If you think my article is useful to you, please feel free to appreciate

Leave a Comment