开发者

PHP UTC Timestamp Creation

I am using ubuntu(apache) for my php application.i need to create a timestamp for authenticated call of a webservice.In php i getting only 10 digit timestamp like 1273229733.But i need to create like 1开发者_StackOverflow中文版273229613000 .How can i solve this problem.help me please.


The thirteen-digit timestamp is the number of milliseconds (1/1,000) since the Unix epoch (compared to the ten-digit seconds since). PHP has a function to return the timestamp to the microsecond (1/1,000,000) which we can multiply and truncate to get our thirteen-digit timestamp.

$millitimestamp = floor(microtime(TRUE) * 1000);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜