pre_wp_is_site_initialized

FILTER wp-includes\ms-site.php (ligne 926) github
Filters the check for whether a site is initialized before the database is accessed. Returning a non-null value will effectively short-circuit the function, returning that value instead.

Paramètres

Entrée :
null, $site_id
Sortie :
@param bool|null $pre     The value to return instead. Default null
@param int       $site_id The site ID that is being checked.

Utilisation

// Modifier la valeur avec le filtre 'pre_wp_is_site_initialized'
add_filter('pre_wp_is_site_initialized', 'ma_fonction_filtre', 10, 1);

function ma_fonction_filtre(null) {
    // Modifier la valeur
    return null;
}

Actualités

Chargement des actualités...