wp_reschedule_event

SummerySummery

Reschedules a recurring event.

Syntax

wp_reschedule_event( int $timestamp, string $recurrence, string $hook, array $args = array() )

DescriptionDescription

Mainly for internal use, this takes the time stamp of a previously run recurring event and reschedules it for its next run.

To change upcoming scheduled events, use wp_schedule_event() to change the recurrence frequency.

ParametersParameters

$timestamp

(int) (Required) Unix timestamp (UTC) for when the event was scheduled.

$recurrence

(string) (Required) How often the event should subsequently recur. See wp_get_schedules() for accepted values.

$hook

(string) (Required) Action hook to execute when the event is run.

$args

(array) (Optional) Array containing each separate argument to pass to the hook's callback function.

Default value: array()

ReturnReturn

(bool) True if event successfully rescheduled. False for failure.

SourceSource

File: wp-includes/cron.php


			

ChangelogChangelog

Changelog
Version Description
5.1.0 Return value modified to boolean indicating success or failure, 'pre_reschedule_event' filter added to short-circuit the function.
2.1.0 Introduced.
Scroll to Top