PHP attempting to make JavaScript friendly timestamp, failing, returns 1.34899651119E+12
Posted
by
chris
on Stack Overflow
See other posts from Stack Overflow
or by chris
Published on 2012-09-30T09:22:16Z
Indexed on
2012/09/30
9:37 UTC
Read the original article
Hit count: 172
Well, not sure whats going on. I have been trying to follow by examples I have found here on stack, on google, even an answer someone gave me a week+ ago, which unfortunately I wasn't able to test until today.
Anyway I am attempting to generate a javascript friendly timestamp via php so I can get my times synced up. The best logic I could find overall was something dealing with microtime. However that doesn't seem to work as expected, not even in the slightest.
Right now I am using microtime(true)*1000;
and am getting 1.34899651119E+12
for the result. Did I some how manage to mess up that one tiny line of code, Im not sure.
© Stack Overflow or respective owner