Skip to content

Instantly share code, notes, and snippets.

@srikat
Last active August 29, 2015 14:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save srikat/873aafe7dee3f9c9dcd1 to your computer and use it in GitHub Desktop.
Save srikat/873aafe7dee3f9c9dcd1 to your computer and use it in GitHub Desktop.
Customize the Author Says text in Genesis comments for Post Author: https://sridharkatakam.com/customize-the-author-says-text-in-genesis-comments-for-post-author/
//* Modify the author says text in comments while showing different text for comments made by author that published the post
add_filter( 'comment_author_says_text', 'sk_comment_author_says_text' );
function sk_comment_author_says_text() {
global $post, $comment;
if ( $comment->user_id === $post->post_author ) {
return '- the post author says';
} else {
return '- the commentator says';
}
}
//* Modify the author says text in comments
add_filter( 'comment_author_says_text', 'sp_comment_author_says_text' );
function sp_comment_author_says_text() {
return 'author says';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment