I am using php any mysql. I would like to create a timer that operates in the server side, and when time reaches a certain value (e.g. 06:00:00), it can trigger the running of another file (such as, update data of a table).
Actually, what kind of technique I shall use apart from php?
Thankyou...
I am using php any mysql. I would like to create a timer that operates in the server side, and when time reaches a certain value (e.g. 06:00:00), it can trigger the running of another file (such as, update data of a table).
Actually, what kind of technique I shall use apart from php?
Thankyou...
Share Improve this question asked Oct 27, 2011 at 9:50 HamHam 8143 gold badges15 silver badges25 bronze badges 1- what would be practical use of this timer? – Your Common Sense Commented Oct 27, 2011 at 11:55
5 Answers
Reset to default 6You should look into cron jobs.
This sounds like you need to use a cron job here is a decent tutorial for you!
Link
You need cron jobs for unix systems and task schedular for Microsoft systems.
It runs files when you set it to.
Obviously if you can use them - cronjobs are the correct solution. But if you just have a little webspace or something where you cant setup cronjobs you need something else. You could of course just do it in php but this istn nice, as you have no guarantee that it runs at specified time, maybe it will much later. The perfect solution to that scenario ist something like a webcron: https://stackoverflow./questions/163476/free-alternative-to-webcron
If you want events to occur on specific times on the server, use crontab
to achieve this on Linux servers or Scheduled Tasks
on Windows servers. You can then schedule the execution of a task at a specific time.