Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor Pippin Williamson

    (@mordauk)

    Hi Anna,

    That is coming from your theme. In order to remove it, you will need to edit a theme template file.

    Are you comfortable doing that?

    Thread Starter Type Historian

    (@type-historian)

    If you can tell me the code and exactly where to enter it, I’m willing to work on solving this nuisance. I’m code-clueless, but good at following directions (and backing up!).

    Thanks so much for your help, Anna

    P.S. I’m starting to figure out how to use EDD, and I like it!

    The code in wp-content/themes/suffusion/comments.php

    if (!$message_disabled) {
    			echo "<p>";
    			_e('Sorry, the comment form is closed at this time.', "suffusion");
    			echo "</p>";
    		}

    You can copy comments.php to your child theme, edit it there and prevent the code from echoing the text

    if (false && !$message_disabled) {
    			echo "<p>";
    			_e('Sorry, the comment form is closed at this time.', "suffusion");
    			echo "</p>";
    		}

    You can also ask in suffusion forum if you can do it from suffusion settings panel (I did not find how)

    Thread Starter Type Historian

    (@type-historian)

    Thank you so much for trying to help me! I followed your instructions and added your code. This is how it looks now:

    }
    	else { // Comments are closed
    		$message_disabled = false;
    		if (is_page() && isset($suf_comments_disabled_all_sel) && $suf_comments_disabled_all_sel == 'all') {
    			$message_disabled = true;
    		}
    		else if (is_page() && isset($suf_comments_disabled_all_sel) && $suf_comments_disabled_all_sel != 'all' && isset($suf_comments_disabled)) {
    			$disabled_pages = explode(',', $suf_comments_disabled);
    			if (is_array($disabled_pages) && count($disabled_pages) > 0 && in_array($post->ID, $disabled_pages)) {
    				$message_disabled = true;
    			}
    		}
    		else if (is_singular() && !is_page() && $suf_comments_disabled_msg_for_posts == 'hide'){
    			$message_disabled = true;
    		}
    
    		if (!$message_disabled) {
    			echo "<p>";
    			_e('Sorry, the comment form is closed at this time.', "suffusion");
    			echo "</p>";
    		}
    
    		if (false && !$message_disabled) {
    			echo "<p>";
    			_e('Sorry, the comment form is closed at this time.', "suffusion");
    			echo "</p>";
    		}

    It didn’t help… Did I do something wrong?

    I’m really confused because I’ve used the same theme since I started with WP, and I already built two related sites–both with comments blocked. This problem started happening suddenly after publishing nearly 150 pages for the EDD one, and now all new pages have this unwanted message. I tried disabling all recent plug-ins, and that didn’t change anything either.

    This is clearly not an EDD problem–maybe someone at the theme forum will be able to help.

    Thank you again for your kindness, Anna

    You are not far ….

    The code should look like that

    }
    	else { // Comments are closed
    		$message_disabled = false;
    		if (is_page() && isset($suf_comments_disabled_all_sel) && $suf_comments_disabled_all_sel == 'all') {
    			$message_disabled = true;
    		}
    		else if (is_page() && isset($suf_comments_disabled_all_sel) && $suf_comments_disabled_all_sel != 'all' && isset($suf_comments_disabled)) {
    			$disabled_pages = explode(',', $suf_comments_disabled);
    			if (is_array($disabled_pages) && count($disabled_pages) > 0 && in_array($post->ID, $disabled_pages)) {
    				$message_disabled = true;
    			}
    		}
    		else if (is_singular() && !is_page() && $suf_comments_disabled_msg_for_posts == 'hide'){
    			$message_disabled = true;
    		}
    
    		if (false && !$message_disabled) {
    			echo "<p>";
    			_e('Sorry, the comment form is closed at this time.', "suffusion");
    			echo "</p>";
    		}

    The additional false in the if condition just disables the test until you find a way to do it via the suffusion settings if you can find how to.

    Thread Starter Type Historian

    (@type-historian)

    Yippeeeeee! You DID it!!!!!

    The nasty message went away as magically as it appeared.

    Ooooooohhhhhhhhh… Thank you SO much.

    Very grateful, Anna

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘How to disable comments?’ is closed to new replies.