I have modified the comment query arguments in comment-template.php
asfrom
$author_id = get_query_var( 'author_id', 1 );
$comment_args = array(
'order' => 'ASC',
'orderby' => 'comment_date_gmt',
'status' => 'approve',
);
$comments = get_comments( $comment_args );
to the following code below
$author_id = get_query_var( 'author_id', 1 );
if($author_id == '') {
$comment_args = array(
'order' => 'ASC',
'orderby' => 'comment_date_gmt',
'status' => 'approve',
);
}
else {
$comment_args = array(
'order' => 'ASC',
'orderby' => 'comment_date_gmt',
'status' => 'approve',
'meta_key' => 'custom_author_id',
'meta_value'=> $author_id,
);
}
$comments = get_comments( $comment_args );
I would like to know how to modify the number of comments being diplayed i.e. get_comments_number()