Previous colleague set up cron
job every 5 min for 24 hrs.
Now I need to modify this only running between 7am to 7pm.
I had never learned cron
job so I googled and tried but it didn't work.
Task Scheduler is set as below
- Begin the task
On a schedule - Settings
One time - Advanced settings
Repeat task every 5 minutes for a duration of Indefinitely
Stop task if it runs longer than 30 minutes
Enabled
And I modified the batch file from
C:\PHP\php.exe -f C:\path\cron.php five-mins
to
*/5 7-19 * * * C:\PHP\php.exe -f C:\path\cron.php five-mins
Even I added */5 7-19 * * * to batch file, it doesn't work.
It would be appreciative if someone can help me. Thanks in advance and thanks for taking your time.