Fix schedule.php SCHEDULE_KEY logic use as a parameter
Current logic does not check $argv and only checks $_REQUEST[‘key’] .
Added in $argv logic whilst retaining the ?key= functionality.
The original WCD instructions state that SCHEDULE_KEY should be used as a
parameter but I cannot see how this would ever work. This code
allows SCHEDULE_KEY to be used as a parameter via cron.
A simple work-around this is to cron -k https://sitedomain.com/schedule.php?key=SCHEDULE_KEY and perhaps this is what has always been done.
Fix schedule.php SCHEDULE_KEY logic use as a parameter
Current logic does not check $argv and only checks $_REQUEST['key'] .
Added in $argv logic whilst retaining the ?key= functionality.
The original WCD instructions state that SCHEDULE_KEY should be used as a
parameter but I cannot see how this would ever work. This code
allows SCHEDULE_KEY to be used as a parameter via cron.
A simple work-around this is to cron -k https://sitedomain.com/schedule.php?key=SCHEDULE_KEY and perhaps this is what has always been done.
Fix schedule.php SCHEDULE_KEY logic use as a parameter
Current logic does not check $argv and only checks $_REQUEST[‘key’] . Added in $argv logic whilst retaining the ?key= functionality.
The original WCD instructions state that SCHEDULE_KEY should be used as a parameter but I cannot see how this would ever work. This code allows SCHEDULE_KEY to be used as a parameter via cron. A simple work-around this is to cron -k https://sitedomain.com/schedule.php?key=SCHEDULE_KEY and perhaps this is what has always been done.
FYI to see how this code already works look at peerupdate.php , it uses $argv[1] and this works OK in cron.
Our scheduler is intended to be used via curl from cron, so this behavior is intentional. I will add an example crontab to the wiki
https://git.oppaiti.me/Oppaitime/Gazelle/wiki/Crontab