smerny Posted August 16, 2009 Report Share Posted August 16, 2009 (edited) It seems like i've seen a few different ways to keep track of date/time... I am currently using the datetime field type of mysql and updating it with NOW(), although I'm thinking maybe I should have used UTC_timestamp?I'm just looking for whichever is most practical, efficient, and accurate for storing times for messages and posts and logs and such and being able to find the differences in time between two times or one time and the current time.... and make the time fit for the users timezone preferenceany thoughts/ideas? Edited August 16, 2009 by smerny Link to comment Share on other sites More sharing options...
ProblemHelpPlease Posted August 16, 2009 Report Share Posted August 16, 2009 My personal solution to using timezones was to let the user set their timezone in the control panel for their account and then store the current date and time based on the server time and adjust the value by the timezone the user had set in their account. This allowed for greater control over managing users based on the users timezones. Link to comment Share on other sites More sharing options...
Synook Posted August 17, 2009 Report Share Posted August 17, 2009 I would store them as UNIX timestamps - that way they are very easy to operate on. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now