i am running a site and i need to set the timezone. which is the most preferable time zone?? my server is in GoDaddy.com. So any one help me to set the time zone开发者_Go百科 via php.
See date_default_timezone_set
As for the time zone: That depends on the nature of your site, I would say.
- You could have the user choose their time zone - nice e.g. for a personalized web app.
- You could set it to the server's time zone - if you don't care
- You could set it to the time zone where your business or user community is located - makes most sense with business sites and localized communities
- You could set it to UTC, as Stack Overflow does. Makes probably the most sense when operating for a global audience, so that things don't get up in inter-user communication ("but in your comment at 2:21 you said...")
精彩评论