当前位置:网站首页>PHP gets the current timestamp three bit MS MS timestamp
PHP gets the current timestamp three bit MS MS timestamp
2022-07-23 13:36:00 【Rudon Binhai fishing village】
<?php
/**
* Get the current three digit number of milliseconds - character string or Integers
*
* @param boolean $return_number Whether to return milliseconds of positive integer type , Default false
*
* @return string|int Number of milliseconds
*/
function get_current_3_digit_millisecond ( $return_number = false ) {
// Get the millisecond string + Integer timestamp
// "0.04009600 1658461202"
list($ms, $timestamp) = explode(' ', microtime());
// Determine whether to return string format
if ($return_number) {
// Integers
$res = intval(substr($ms, 2, 3));
} else {
// character string
$res = substr($ms, 2, 3);
}
return $res;
}
// Example
$nums = get_current_3_digit_millisecond();
var_dump($nums); // "040"边栏推荐
- 中国在又一个新兴科技领域领先美国,站在科技创新制高点
- Netease white hat hacker training camp notes (2)
- Bit synchronization process of CAN controller
- Opencv image processing (medium) image smoothing + histogram
- Wu Enda machine learning series p31~p42
- The principle of Google interview questions is to analyze 12 table tennis balls, one of which is defective. Weigh it with a balance for 3 times to find it
- kubernetes 的这几种存储卷,别再傻傻分不清了
- com.mysql.cj.jdbc.exceptions. MysqlDataTruncation: Data truncation: Truncated incorrect DOUBLE value:
- Day 12 notes
- Target segmentation for 10000 frames of video, with less than 1.4GB of video memory | eccv2022
猜你喜欢

PHP connecting to SQL Server
![[daily training] 814. Binary tree pruning](/img/c1/d71e6190a1855a392689b55503f75e.png)
[daily training] 814. Binary tree pruning
![[jzof] 10 Fibonacci series](/img/65/ab5b22b0879644c210abb38b0ce640.png)
[jzof] 10 Fibonacci series

"100 Android interview questions" I brushed angrily for Dachang

Debug No5基础光照

Running matlab program on GPU

Introduction to radar part vii 4 SAR system design

Remote editing and debugging with vscode

倍福PLC和C#通过ADS通信传输int类型变量

ES6——周考题
随机推荐
Image processing image feature extraction and description
Charles' bag grabbing tool test practice
keepalived双机热备
学会用canvas构建折线图、柱状图、饼状图
[jzof] 10 Fibonacci series
Jupyter notebook add existing virtual environment
Beifu PLC and C transmit bool type variables through ads communication
射击 第 1-01 课:入门
2022-07-22 回顾链表操作以及部分问题
“算力猛兽”浪潮NF5468A5 GPU服务器开放试用免费申请
倍福PLC和C#通过ADS通信传输String数组类型变量
ROS2自学笔记:URDF机器人建模
[jzof] 09 realize queue with two stacks
Compilation and preprocessing
高性能JVM的参数
Power BI----综合应用
Matplotlib- implement common probability distributions
太空射击 Part 2-3: 子弹与敌人碰撞处理
Why choose AMD epyc for cloud solutions?
编译与预处理