开发者

How to store dates in a portable way? [duplicate]

This question already has answers here: Closed 11 years ago.

Possible Duplicates:

Does PHP time() return a GMT/UTC Timestamp?

What's the best way to manage dates across PHP, MySQL, etc?

I want to store timestamps and then format them according to say, the user's timezone preference.

But I don't fully understand what the number returned by time() is.

Does it depend on the machine's timezone config?

Should I standarize it to UTC+0 before storing it?

If I use the same unix timestamp in different machines (different time zones) and format it with date(), will I have the same time (I don't mean the same format, but the sa开发者_运维技巧me point in time)

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜