WordPress at a glance
filter is not described

comment_author filter-hook . WP 1.2.0

Filters the comment author's name for display.

Usage

add_filter( 'comment_author', 'filter_function_name_2364', 10, 2 );
function filter_function_name_2364( $author, $comment_ID ){
	// filter...

	return $author;
}
$author(string)
The comment author's username.
$comment_ID(int)
The comment ID.

Notes

  • Since 4.1.0 The $comment_ID parameter was added.

Where the hook is called

comment_author()
comment_author
wp-includes/comment-template.php 71
echo apply_filters( 'comment_author', $author, $comment->comment_ID );

Where the hook is used (in WP core)

wp-admin/includes/class-wp-comments-list-table.php 45
add_filter( 'comment_author', array( $this, 'floated_admin_avatar' ), 10, 2 );
wp-includes/default-filters.php 123
add_filter( $filter, 'wptexturize' );
wp-includes/default-filters.php 124
add_filter( $filter, 'convert_chars' );
wp-includes/default-filters.php 125
add_filter( $filter, 'esc_html' );