apply_filters( 'cron_request', array $cron_request_array, string $doing_wp_cron )
- Since
- 3.5.0, 4.5.0
Filters the cron request arguments.
Compatibility
- WordPress
- since 4.5.0
- 6.7.7
- 6.8.8
- 6.9.7
- 7.0.4
- 7.1.0
Present in every tracked release (6.7.7 to 7.1.0).
Parameters
$cron_request_arrayarray- { An array of cron request URL arguments.
@type string $url The cron request URL.
@type string $key The Unix timestamp (UTC) of the cron lock with microseconds.
@type array $args { An array of cron request arguments.
@type int $timeout The request timeout in seconds. Default .01 seconds.
@type bool $blocking Whether to set blocking for the request. Default false.
@type bool $sslverify Whether SSL should be verified for the request. Default false.
} }$urlstringThe cron request URL.$keystringThe Unix timestamp (UTC) of the cron lock with microseconds.$argsarrayAn array of cron request arguments.$timeoutintThe request timeout in seconds. Default .01 seconds.$blockingboolWhether to set blocking for the request. Default false.$sslverifyboolWhether SSL should be verified for the request. Default false.
$doing_wp_cronstring- The Unix timestamp (UTC) of the cron lock with microseconds.
Where this hook fires · 1
wp-includes/cron.php:984spawn_cron()
Source code
* @type bool $blocking Whether to set blocking for the request. Default false. * @type bool $sslverify Whether SSL should be verified for the request. Default false. * } * } * @param string $doing_wp_cron The Unix timestamp (UTC) of the cron lock with microseconds. */ $cron_request = apply_filters( 'cron_request', array( 'url' => $cron_url, 'key' => $doing_wp_cron, 'args' => array( 'timeout' => 0.01,Changelog
Introduced in 3.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
4.5.0
The
$doing_wp_cron parameter was added.from the docblock3.5.0
Introduced.from the docblock
About this page
- Parsed data
- Generated from the wordpress-develop 7.1.0 tag, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
- Corrections
- Something wrong on this page? Report it and it gets fixed in the next regeneration.