WordPress.org

Support

Support » Themes and Templates » How to remove the comments form

How to remove the comments form

  • I’d like to remove the comments form from a child of th Twenty Eleven theme.

    Any ideas, please?

Viewing 5 replies - 1 through 5 (of 5 total)
  • cdukes

    @walkinonwat3r

    You could:
    -Disable commenting in Settings > Discussion
    -Disable commenting on a specific post in the editor
    -Hide the comment box with display: none
    -Or remove the comment hook from the single.php file

    Karun

    @karunshakya45

    Copy the single.php and page.php file to your child theme and in single.php and page.php the is a line

    <?php comments_template( ”, true ); ?>

    , remove it or comment it.

    Thank you, Cooper. I’m more interested in removing the comments from the “pages” than the “posts”. Can you tell me how do I hide the comment box with display:none?

    Thanks, karunshakya45, but it didn’t work for the pages, only for posts.

    Got it. Removed the line from the sidebar-page.php (the template for all the pages)!

    Resolved.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How to remove the comments form’ is closed to new replies.
Skip to toolbar