in reply to Re^2: calculating 24 hours ago with localtime
in thread calculating 24 hours ago with localtime

using NOW(), how would I setup the database then? Right now I am using time VARCHAR(25) for the time field and I am inserting the $localtime as a string.

When you create your database table, use a datetime data type for your time field.

The mysql NOW() function returns the current date/time, so you simply use this for both your INSERTs and DELETEs

Cheers,
Darren :)

  • Comment on Re^3: calculating 24 hours ago with localtime