3 * WordPress Cron Implementation for hosts, which do not offer CRON or for which
4 * the user has not setup a CRON job pointing to this file.
6 * The HTTP request to this file will not slow down the visitor who happens to
7 * visit when the cron job is needed to run.
12 ignore_user_abort(true);
15 * Tell WordPress we are doing the CRON task.
19 define('DOING_CRON', true);
20 /** Setup WordPress environment */
21 require_once('./wp-load.php');
23 if ( $_GET['check'] != wp_hash('187425') )
26 if ( get_option('doing_cron') > time() )
29 update_option('doing_cron', time() + 30);
31 $crons = _get_cron_array();
32 $keys = array_keys($crons);
33 if (!is_array($crons) || $keys[0] > time())
36 foreach ($crons as $timestamp => $cronhooks) {
37 if ($timestamp > time()) break;
38 foreach ($cronhooks as $hook => $keys) {
39 foreach ($keys as $key => $args) {
40 $schedule = $args['schedule'];
41 if ($schedule != false) {
42 $new_args = array($timestamp, $schedule, $hook, $args['args']);
43 call_user_func_array('wp_reschedule_event', $new_args);
45 wp_unschedule_event($timestamp, $hook, $args['args']);
46 do_action_ref_array($hook, $args['args']);
51 update_option('doing_cron', 0);