Of course I am very new to PHP.
I have a download script that I'd like to keep track and clear the downloads every day. I have the script coded to where it counts, but what I am having trouble with is how do I know when to clear the counts and start over the next day? What is the best way? Playing with UNIXTIME stamp, I discovered the difference in one day to the next is 86400 units.
Is this the way I should approach this problem? I figured maybe I am going down the wrong road here.
I need to check the time with each download, see if it's passed midnight the next day.
If it is, then I need to erase all the download counts back to ZERO.
Should I do that with a time() or would I just look at the time and see if's it less than current time?
Any suggestions?