Mysql table/PHP question help

Kirk

Well-known member
Hey everyone,

So as you guys might of seen i'm trying to attempt to make a quiz add-on for xenForo. Right now I'm trying to work on creating the tables for the addon and i'm having trouble on how i should go about trying to implement the timer for the adddon. I thought it would be a decimal type or a tiny int.

If someone could help me i would greatly appreciate it. :)
 
If you are running a timer, you should be doing it client side and not server side. However, if you want to guarantee you receive an answer in a specific amount of time, you could store a start time and an end time in a UNIX time stamp and then use time() to compare between the two.
 
As Jeremy said, store a UNIX time stamp. Your date field(s) will need to be a int(10).
 
Back
Top Bottom