开发者

How do Social Networking applications convert server time according to viewer's timezone

How to convert the UTC time according to viewer's timezone?

I heard that it's not possible to get the timezone of the viewer, but then ho开发者_运维技巧w do social networking services like FB, twitter do this ?

Edit: I have registered users on my application.


  • It is possible to get the user timezone, but this is done with javascript (get the detect_timezone.js). You most likely do that when users are registered.

  • Another, worse way is to approximate the timezone based on the IP

  • and finally (with combination of any of the above), you can give the user a choice to select his timezone in his settings

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜