Using crontab to execute script every hour for 24 hours

To execute a PHP script every 24 hours, you can use @daily or 0 0 * * * followed by the location of the PHP binary executable, the -q flag, and the path of the .php file:

0 0 * * * /usr/bin/php -q script_directory/cron.php  

Leave a Comment