• I only wish to have the comments box on the home page of my site. How can I remove the comments box from all of my other pages.

    I also would like to change the “no comments” words above the comments box to add comment. How can I do this.

    My site is http://www.gurumumma.com

    Your assistance is greatly appreciated. Rachel J

Viewing 11 replies - 1 through 11 (of 11 total)
  • Hi Rachel,

    When you say you only want the comment box only in the home, do you mean you do not want it when you access individual posts?
    If this is the case, and depending on what template you’re using, there’s a piece of code you need to get rid of in your single.php file and in all the other files loading the comment feature.
    Same thing goes with altering the “No comments” message to “add comments”. You need to modify your template in order to customize this.
    If you tell me what template you’re using I’ll tell you exactly what lines you have to delete and in which files.

    Cheers!

    Easier way, without having to fiddle with the codes is: In the write panel (for post or page), go to the Discussion area and un-tick the “Allow comments” box. Done.

    By doing this, you can turn the comment box on and off at will for your posts/pages, instead of totally disabling it (who knows you may recover from your allergy to the comment box).

    Hi Mished, you’re right about disabling the comments. However, in order to change the “No comments” message to “Add comments”, you do have to perform some code editing.
    However, I noticed that when you are in the home page of your site and you click on the “Add comments” button right next to the date, it seems to take you inside the post to add that comment, so if you do disable the comments feature inside posts (single.php file), you won’t be able to add comments, not even from the home page. But in order to be 100% sure, it would be best if I knew what template you’re using, so I can take a look at how it is coded.
    Mished, what do you think?

    Also, I noticed that in Safari 3.2.2 and Google Chrome 3.01 your sidebar does not display right: Categories, Join Ummagumma and Search Bar display one on top of the other.

    By saying How can I remove the comments box from all of my other pages, Rachel did NOT mean disabling commenting. She only wanted to hide the comment area, and for it to be made visible only after clicking an ADD COMMENT link.

    It just goes to show how unclear her spec was … or how muddled my thinking was. I really shouldn’t waste my time coming up with a solution that’s way off the mark.

    Hey mished, I don’t think your post was a waste of time: I mean, I hadn’t thought of it, and God knows that, in theory, your solution is way more practical, 🙂
    Indeed, your solution works in a way, but you have to implement it a little differently. I can’t believe my brain did not go here off the bat instead of to some complicated template modification (at least for enabling/disabling comments).
    Rachel, here’s what you should do:
    1. Go to your Dashboard, and under the “Settings” title, click on “Discussion” (this is under WP’s latest version, 2.9.1, because you did not specify what version of WP you’re running). Make sure that the option “Allow people to post comments on new articles” is checked. While you are here, you might want to take the time to customize your settings a little to suit them better to your needs.
    2. Assuming your “About,” “Recommendations,” and “Contact” sections were added to your blog as Pages, and still in the admin panel, go to the “Pages” section. Notice that when you position your mouse on top of any of your pages, a menu appears with the following options: “Edit | Quick Edit | Trash | View”. Place your mouse on top of the first page that is listed, and when the menu comes up, Click on “Edit.” This will take you to the editing window. Scroll down a little, and you will notice a submenu entitled “Discussion.” In that submenu, uncheck the “Allow Comments” option. This will disable the comment feature in that page. Repeat this procedure for all the pages in which you wish to disable the comments feature, and presto, you are done!
    LMK if that worked.
    Good luck!

    BTW, I almost forgot. In order to change “No Comments” to “Add comments”, follow this procedure.
    1. Sign in into your admin section.
    2. Go to “Appearance” and then to “Editor.”
    3. Inside the “Editor,” you will find a list of “Theme files” on the right side of the screen. Look for a file called “Comments” and/or “Comments.php” and click on it. Although this varies from theme to theme, there’s a 99% chance you will have such a file. This will bring out the “comments.php” for editing.
    4. Use your browser “Search” feature to look for this piece of code:
    <h3>No Comments</h3> and replace it with this code: <h3>Add Comments</h3>.
    And Voilà, you’re good to go.

    It would be nice if the original poster actually replied to both mished posts and mine, and let us know if the problem was fixed.
    Seems like minimal courteous thing to do here…

    Rach,

    If you were able to figure this one out, could you mark the thread as resolved? It helps a lot to filter out which threads were solved and which were not.

    Thanks.

    Hi,
    I really want to totally remove the comment box and text “add comment” how do I do this.
    I need to have them bot totally removed forever on this site,thanks
    sincerely
    David Goodwin

    search the template files of your theme for ‘comments_template();’ and ‘comments_popup_link()’ and remove the code with the associated html tags.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Comments box’ is closed to new replies.