post_type_labels_{$post_type}

FILTER wp-includes\post.php (ligne 2173) github
Filters the labels of a specific post type. The dynamic portion of the hook name, `$post_type`, refers to the post type slug. Possible hook names include:  - `post_type_labels_post`  - `post_type_labels_page`  - `post_type_labels_attachment`

Paramètres

Entrée :
$labels
Sortie :
@param object $labels Object with labels for the post type as member variables.

Utilisation

// Modifier la valeur avec le filtre 'post_type_labels_{$post_type}'
add_filter('post_type_labels_{$post_type}', 'ma_fonction_filtre', 10, 1);

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

Actualités

Chargement des actualités...