• My page is at: https://www.lensaunders.com/wp/

    At the top of the page, there are 3 links….Home, Terms, Contact.

    On all those pages, there is a place to post a comment. Is there a way to take off the ability to post comments on these pages. I want visitors to only be able to post on my ‘posting’ pages. Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You have a couple of ways to do this:

    1) Remove the <?php comments_template(); ?> line in page.php template, but this isn’t the most preferred method.

    2) When you edit the page, scroll to the bottom where you see Comments, and uncheck allow comments. This will display “Comments are closed” in the comments section.

    3) You can create a page template and remove the <?php comments_template(); ?> like in step 1 and use this page template for any pages you don’t want comments to show up on.

    Thread Starter childrensfitness

    (@childrensfitness)

    Thank you peiqinglong. You are most helpful. I did step number 2 and it worked. My question, is there a way to get rid of the “Comments are closed” text?

    I was wondering if I follow step 1, would it accomplish this? When you say it is ‘not preferred’, does it present any dangers? Thanks.

    The best way to get rid of the comments are closed is to do step 3. That way you can remove the entire <?php comments_template(); ?> line out of the template.

    The reason step 1 isn’t preferred is: what if you want comments? If you remove the call for the comments, you’re ENTIRE site will have no comment form.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Removing “Posting” section on static pages’ is closed to new replies.