Number to increase automatically
Moderator: General Moderators
Number to increase automatically
I'm relatively new to PHP and MySQL, and I want to write a code which updates a certain value by adding one each hour or day or something. Could anyone help me?
Re: Number to increase automatically
yes it is possible, you can base that incrementing of value from the computer's system time.
Re: Number to increase automatically
Wouldn't that mean a user could increase this value by simply adjusting the clock on his computer?it2051229 wrote:yes it is possible, you can base that incrementing of value from the computer's system time.
Re: Number to increase automatically
you never mentioned THAT it interacts with user. now i'm confusedI'm relatively new to PHP and MySQL, and I want to write a code which updates a certain value by adding one each hour or day or something
Re: Number to increase automatically
sorry, I'll explain it further.it2051229 wrote:you never mentioned THAT it interacts with user. now i'm confused
What I'm trying to do is to write a script which will increase the value for the users constantly, say by 1 per hour or something. And I might be wrong but if it's set after the different users' computer watches, wouldn't that make it easy to "cheat" having the value increase more than it's supposed to, by adjusting the time?
Re: Number to increase automatically
i'm talking about the "server" time, not the client's computer time so they can't cheat unless someone(e.g. you) has access to the server computer and do it.