Quote:
Originally Posted by SemperFideles
I did a test run and get this error:
PHP Code:
Turn off Forum
Warning: include_once([path]/./includes/cron/forumswitch.php?enable=0) [function.include-once]: failed to open stream: No such file or directory in [path]/admincp/cronadmin.php on line 113
Warning: include_once() [function.include]: Failed opening '[path]/./includes/cron/forumswitch.php?enable=0' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in [path]/admincp/cronadmin.php on line 113
Done
|
Hmmm, seels like Scheduled Tasks don't accept filenames with query string attached ...
Two alternatives:
- Either forget about scheduled tasks and simply invoke the forumswitch.php manually at specified time
- Or wrap the forumswitch.php code into a function that takes the $enable value (true/false), and then create two separate files that include the forumswitch.php and call the function with either true or false respectively. Use these separate files in the scheduled tasks.