Allows the HTML for a user's avatar to be returned early. Returning a non-null value will effectively short-circuit get_avatar(), passing the value through the {@see 'get_avatar'} filter and returning early.
null, $id_or_email, $args
Sortie :
@param string|null $avatar HTML for the user's avatar. Default null. @param mixed $id_or_email The avatar to retrieve. Accepts a user ID, Gravatar MD5 hash, @param array $args Arguments passed to get_avatar_url(), after processing.
// Modifier la valeur avec le filtre 'pre_get_avatar'
add_filter('pre_get_avatar', 'ma_fonction_filtre', 10, 1);
function ma_fonction_filtre(null) {
// Modifier la valeur
return null;
}
Chargement des actualités...