On this page
wp_schedule_update_network_counts()
Schedules update of the network-wide counts for the current network.
Source
File: wp-includes/ms-functions.php. View all references
function wp_schedule_update_network_counts() {
if ( ! is_main_site() ) {
return;
}
if ( ! wp_next_scheduled( 'update_network_counts' ) && ! wp_installing() ) {
wp_schedule_event( time(), 'twicedaily', 'update_network_counts' );
}
}
Related
Uses
| Uses | Description |
|---|---|
| wp_installing() wp-includes/load.php | Check or set whether WordPress is in “installation” mode. |
| wp_next_scheduled() wp-includes/cron.php | Retrieve the next timestamp for an event. |
| wp_schedule_event() wp-includes/cron.php | Schedules a recurring event. |
| is_main_site() wp-includes/functions.php | Determines whether a site is the main site of the current network. |
Changelog
| Version | Description |
|---|---|
| 3.1.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/wp_schedule_update_network_counts