wp_theme_json_data_theme

FILTER wp-includes\class-wp-theme-json-resolver.php (ligne 292) github
Filters the data provided by the theme for global styles and settings.

Paramètres

Entrée :
new WP_Theme_JSON_Data( $theme_json_data, 'theme'
Sortie :
@param WP_Theme_JSON_Data $theme_json Class to access and update the underlying data.

Utilisation

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

function ma_fonction_filtre(new WP_Theme_JSON_Data( $theme_json_data) {
    // Modifier la valeur
    return new WP_Theme_JSON_Data( $theme_json_data;
}

Actualités

Chargement des actualités...