I've got a wordpress plugin that allows Facebook leaving comments using blogging platforms. Customers have asked for an element which will hide the default WordPress comments form on posts where Facebook leaving comments is enabled.

How do you start hiding the Wordpress comments form quickly? I understand I'm able to comment out comment_form(); in the comments.php template, but Let me have the ability to hide/unhide it in the click a control button.

Is there something related to the comments_template filter?

The plugin's home page is http://grahamswan.com/facebook-comments

Wrap the shape inside a div and employ this straightforward bit of jquery to exhibitOrconceal the div.

<div class="comments">
<?php comment_form(); ?>
</div>

<a class="comment_switch">Show / Hide Comments</a>

.hidden{display:none;}

$("comment_switch").click(function () {
     $("comments").toggleClass("hidden")");
   });