Dkuzik Posted September 19, 2022 Share Posted September 19, 2022 Anyone now why this hook isn't working. Have latest version of WHMCS. Was working when I first tried on previous version. sorry couldn't paste code wasn't letting me. https://github.com/Katamaze/WHMCS-Action-Hook-Factory/blob/master/hooks/DailyCronJonOnDemand.php Link to comment Share on other sites More sharing options...
leemahoney3 Posted September 19, 2022 Share Posted September 19, 2022 Hiya Dkuzik, Have you changed the directory of your crons folder? (e.g. outside of your public document root) Link to comment Share on other sites More sharing options...
Dkuzik Posted September 20, 2022 Author Share Posted September 20, 2022 No its in default folder. All my other hooks work. Hooks debug doesn't show anything wrong. Using Blend admin theme. See image nothing showing Link to comment Share on other sites More sharing options...
leemahoney3 Posted September 20, 2022 Share Posted September 20, 2022 (edited) 7 hours ago, Dkuzik said: No its in default folder. All my other hooks work. Hooks debug doesn't show anything wrong. Using Blend admin theme. See image nothing showing It's possible WHMCS has changed how the crons are run, I'll have a look later. If you run the cron file manually (e.g. https://yourdomain.com/crons/cron.php), can you confirm it works? Check Last Cron Invocation under Automation Status. Edited September 20, 2022 by leemahoney3 Link to comment Share on other sites More sharing options...
Dkuzik Posted September 21, 2022 Author Share Posted September 21, 2022 There are no hook errors hooks in default directory Hooks Debug: Hook File Loaded: /www/wwwroot/mydomain.com/billing/includes/hooks/DailyCronJobOnDemand.php None Admin ID 1 09/20/2022 18:22 Hooks Debug: Hook Defined for Point: AdminAreaHeaderOutput - Priority: 1 - Function Name: (anonymous function) None Admin ID 1 09/20/2022 18:22 Hooks Debug: Attempting to load hook file: /www/wwwroot/mydomain.com/billing/includes/hooks/DailyCronJobOnDemand.php Link to comment Share on other sites More sharing options...
Kian Posted November 14, 2022 Share Posted November 14, 2022 On 9/20/2022 at 5:06 AM, Dkuzik said: No its in default folder. All my other hooks work. Hooks debug doesn't show anything wrong. Using Blend admin theme. See image nothing showing It doesn't show anything because the hook was made for WHMCS v5, v6 and v7. The current admin template has changes that prevent jQuery from finding a CSS selector on the page. Btw I updated the code so that the Run Daily Cron button is displayed on top of the sidebar as follows. Link to comment Share on other sites More sharing options...
Dkuzik Posted November 14, 2022 Author Share Posted November 14, 2022 Right on. Thanks. Btw it was working on my previous version 8.? Link to comment Share on other sites More sharing options...
Recommended Posts