Codex tools: Log in
Contents |
Un-schedules a previously-scheduled cron job.
<?php wp_unschedule_event( $timestamp, $hook, $args ); ?>
Note that you need to know the exact time of the next occurrence when scheduled hook was set to run, and the function arguments it was supposed to have, in order to unschedule it. All future occurrences are un-scheduled by calling this function.
This function does not return a value
<?php $timestamp = wp_next_scheduled( 'my_schedule_hook' ); wp_unschedule_event($timestamp, 'my_schedule_hook', original_args ); ?>
Since: 2.1.0
wp_unschedule_event() is located in wp-includes/cron.php