the_author_{$field}

FILTER wp-includes\author-template.php (ligne 222) github
Filters the value of the requested user metadata. The filter name is dynamic and depends on the $field parameter of the function.

Paramètres

Entrée :
$author_meta, $user_id
Sortie :
@param string    $author_meta The value of the metadata.
@param int|false $user_id     The user ID.

Utilisation

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

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

Actualités

Chargement des actualités...