Hi, im new here, nice forum!
i got a problem... What about if you want to run a script every monday, everytime a user log in, like a monday's surprice
if (date("D") == 'Mon') {
RUN SCRIPT; }
else { NOTHING }
the problem is, with this method the user could change their computer date and get the surprice any day at any time, just need to change their computer date to monday. How can i do to instead of check for the user's time, to check the time of the server where the website is hosted?
Thanks!




Reply With Quote
the date uses the time (hours/minutes/seconds) of the guest but the date (month/day/year) of the server. Problem fixed, thanks!.

Bookmarks