Reputation: 30411
How can I run a php file or execute a mySQL query automatically depending on the time? For example, by 12mn I want my server to automatically run somefile.php.
More: I have a LAMP setup.
Upvotes: 0
Views: 240
Reputation: 736
If you don't want to setup a cron job (or if you can't) you can use a service like WebBasedCron
Upvotes: 0
Reputation: 2405
You can do this by using Cron :
https://help.ubuntu.com/community/CronHowto
ex :
* */12 * * * php /cron/script.php
Upvotes: 0
Reputation: 86336
You are looking for the Cron jobs. you can schedule the PHP file to be executed with the cron and cron will take care of rest.
If you are on LAMP platform, check out how to setup cron.
Upvotes: 3