the_author
Filters the display name of the current post's author.
Usage
add_filter( 'the_author', 'wp_kama_the_author_filter' ); /** * Function for `the_author` filter-hook. * * @param string $display_name The author's display name. * * @return string */ function wp_kama_the_author_filter( $display_name ){ // filter... return $display_name; }
- $display_name(string)
- The author's display name.
Changelog
Since 2.9.0 | Introduced. |
Where the hook is called
the_author
wp-includes/author-template.php 38
return apply_filters( 'the_author', is_object( $authordata ) ? $authordata->display_name : '' );
Where the hook is used in WordPress
wp-includes/default-filters.php 260
add_filter( 'the_author', 'ent2ncr', 8 );