Please wait, loading...

 

Disable or Disallow Comments in Wordpress - Emerald Tech

June 14, 20120

You can disable comments in wordpress easily. The trick is to go to Settings -> Discussion -> then uncheck option “Allow people to post comments on new articles”

This setting applies to all new posts that will be published from now onwards. To disable comments from posts that have been published.

Posts -> select all then click “Edit” under bulk actions and click apply >> choose “do not allow” next to comments and hit update posts.

If you don’t want the comment form to show on any post or pages then locate all occurrences of the code below and remove it.


<?php comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')); ?>

I you don’t want the text “Comments off” to be displayed then look for wp-icludes/comment-template.php and open it in a notepad. Change the line


function comments_popup_link( $zero = 'No Comments', $one = '1 Comment', $more = '% Comments', $css_class = '', $none = 'Comments Off' )

to


//change $none = 'Comments Off' to $none = ''
function comments_popup_link( $zero = 'No Comments', $one = '1 Comment', $more = '% Comments', $css_class = '', $none = '' )

Yumna Tatheer

Leave a Reply

Your email address will not be published. Required fields are marked *

Copyright @ Yamna Tatheer CEO Emerald Technologies Registration Number: 3520166158082