WP Cron jobs loops infinitely

I usually define a IF state and use wp_clear_scheduled_hook function. See example: if (get_option(‘atenasupervisor_scheduler’) <> ‘Stop’) { echo ‘Active (‘. get_option(‘atenasupervisor_scheduler’).’)</strong></div>’; } else { wp_clear_scheduled_hook( ‘atenasupervisor_my_email’ ); echo ‘Not active (‘. get_option(‘atenasupervisor_scheduler’).’)</strong></div>’; } “

wp-cron: freeze at “now”

Mmmh, some progress: I’m able to activate wp-cron by browser (not really clear, because I have a white screen…): anyway, if I browse wp-cron, jobs are correctly executed and rescheduled… Now I have to understand why crontab do not work…

wp-cron.php – timeout

I had the same problem. My solution was to define the timeout constant for the cron job by adding this line in wp-config.php: define(‘WP_CRON_LOCK_TIMEOUT’, 60); I added this before the line require_once(ABSPATH . ‘wp-settings.php’); and it worked. By default this is set to 0.01 seconds, which to me it makes no sense. This line sets … Read more

Hourly scheduled wp_cron job keeps getting rescheduled

Well….I’ve figured it out. Manually deleting everything in Crontrol didn’t help as much as I thought it had. I went to my wp_options table and deleted the entire cron entry. On refresh now, everything looked more or less how I expected, and all of my questions are answered now. When disabling WP Cron to enable … Read more

wp_schedule_single_event does not call my action

Because you’re scheduling the event – even though it’s set to run immediately (i.e. with time()), it won’t fire until a second request. So that log output is entirely expected. Try running it again, removing the code, then run once more – you should get: [time] test_action