Closed phyzical closed 1 month ago
yes, just create a cron.php file in plugin root with code like:
<?php
/*
* Simple Cron job
*/
$GLOBALS['cron'][] = [
'class' => 'ShuckStop', // Class name of plugin (case-sensitive)
'enabled' => 'SHUCKSTOP-cron-run-enabled', // Config item for job enable
'schedule' => 'SHUCKSTOP-cron-run-schedule', // Config item for job schedule
'function' => '_shuckStopPluginRun', // Function to run during job
];
well i feel silly that i didn't even bother to search it...
Thanks for the speedy reply though!
Hey i've created this plugin to support auto discovery https://github.com/phyzical/autoOrganizr
i was just wondering if there is logic to allow plugins to create a cron to be run in the core of the application?
Just want to run this logic https://github.com/phyzical/autoOrganizr/blob/main/plugin.php#L267 in the background some how
Just to avoid users being forced to click the menu item to sync the tabs