wp_is_large_user_count
Filters whether the site is considered large, based on its number of users.
Использование
add_filter( 'wp_is_large_user_count', 'wp_kama_is_large_user_count_filter', 10, 3 );
/**
* Function for `wp_is_large_user_count` filter-hook.
*
* @param bool $is_large_user_count Whether the site has a large number of users.
* @param int $count The total number of users.
* @param int|null $network_id ID of the network. `null` represents the current network.
*
* @return bool
*/
function wp_kama_is_large_user_count_filter( $is_large_user_count, $count, $network_id ){
// filter...
return $is_large_user_count;
}
- $is_large_user_count(true|false)
- Whether the site has a large number of users.
- $count(int)
- The total number of users.
- $network_id(int|null)
- ID of the network. null represents the current network.
Список изменений
| С версии 6.0.0 | Введена. |
Где вызывается хук
wp_is_large_user_count
wp-includes/user.php 1590
return apply_filters( 'wp_is_large_user_count', $count > 10000, $count, $network_id );