Is there a quick way to disable all comments on all posts and pages. I know that you can go into the dashboard under posts, click edit, and Do Not Allow, under comments. Is that the only way?
Leave a Reply
You must be logged in to post a comment.
Is there a quick way to disable all comments on all posts and pages. I know that you can go into the dashboard under posts, click edit, and Do Not Allow, under comments. Is that the only way?
You must be logged in to post a comment.
The check if comments are enabled is performed by
comments_open()
function.You can make it always return false via a filter with something like this:
Other way would be to make comments available to only registered users (that is if you don’t have open registration) in
Settings > Discussion
.I have write an plugin for this job.
https://github.com/bueltge/Remove-Comments-Absolutely
WordPress has on many different points jobs and views for comments, if you will not use all this, use the plugin or customize the source for your requirements.
Bulk edit the existing pages in the dashboard Posts or Pages view as noted here:
I thought I’d add an answer to the above as it may not be immediately obvious to others searching for this issue.
In Settings >> Discussion you can uncheck “Allow people to post comments on new articles” in the Default article settings.
However, note that this will only affect new posts/pages.
You can bulk edit the existing pages in the dashboard Posts or Pages view.
This may be a preferred method for some people not wanting to touch the template files, etc.
Not including the comment-form in your theme also works (that’s what I usually do).