Skip to content

Instantly share code, notes, and snippets.

@TANVIRFAZLEY
Last active October 8, 2022 11:54
Show Gist options
  • Save TANVIRFAZLEY/5979059e278dbd87da8b17a8824bd3f4 to your computer and use it in GitHub Desktop.
Save TANVIRFAZLEY/5979059e278dbd87da8b17a8824bd3f4 to your computer and use it in GitHub Desktop.
comments template count title
<?php
$morus_comment_count = get_comments_number();
if ( $morus_comment_count <= 1 ) {
echo "(" . esc_html( $morus_comment_count ) . ")" . __( ' Comment', 'morus' );
} else {
echo "(" . esc_html( $morus_comment_count ) . ")" . __( ' Comments', 'morus' );
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment