WebsiteCreator
WebsiteCreator

Reputation: 23

Reset the comment count

How do I reset the comment count visible in the permalink when a user is posting a new comment? For an example see the picture below:

"#comments-..."

I have deleted all comments on my site but the 'counter' keeps counting.

The comment count is caused by a default Wordpress code (in the wp-comments-post.php file) shown belown:

$location = empty( $_POST['redirect_to'] ) ? get_comment_link( $comment ) : $_POST['redirect_to'] . '#comment-' . $comment->comment_ID;

Upvotes: 0

Views: 892

Answers (1)

Syaiful Bachri
Syaiful Bachri

Reputation: 119

In my case, I fixed it by made a dummy comment on a post. Then Comments section in Admin Dashboard recounted. Then simply delete that dummy comment will reset it to zero.

Upvotes: 1

Related Questions