How to Remove Comments Section from a WordPress Theme

February 6, 2014 — 4 Comments

If you are looking to remove comments section from your WordPress theme and I’ve got really way to do this within a couple of minutes. And I hope this make sense. There may be a couple of reasons about why you want to remove comments section from your WordPress theme etc. In this article, I’ve shared a pretty good technique about removing comments section for any WordPress theme.

Let me know if you want to remove comments from only Pages or Posts. However, both are same, the difference is only in the theme files that we are about to edit.

All we need to do in order to remove comments from WordPress, is to simply trigger out the following WordPress core template tag (‘comments_template()‘), like so. The files you need to edit to remove the following template tag from your WordPress theme are (single.php and page.php).

<?php comments_template(); ?>

So, If you want to remove comments section from your blog posts simply remove the comment template tag from single.php for pages just edit the page.php file.

4 responses to How to Remove Comments Section from a WordPress Theme

  1. Sir I m trying but not done my blog is not open after edit the file pls help

  2. Ohhh Wahoooooo Wahooo.

    Borther i M trying and i fix that. i realy thank full to you about this tip.

Leave a Reply

*

Text formatting is available via select HTML. <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>