Title: getting just the count
Last modified: August 24, 2016

---

# getting just the count

 *  Resolved [akehat](https://wordpress.org/support/users/akehat/)
 * (@akehat)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/)
 * I want to get just the count of FB comments. How do I get it?
 * Thanks
 * [https://wordpress.org/plugins/facebook-comments-plugin/](https://wordpress.org/plugins/facebook-comments-plugin/)

Viewing 10 replies - 1 through 10 (of 10 total)

 *  [Alex Moss](https://wordpress.org/support/users/alexmoss/)
 * (@alexmoss)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164372)
 * Instructions are within the plugin homepage
 *  Thread Starter [akehat](https://wordpress.org/support/users/akehat/)
 * (@akehat)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164390)
 * On the plugin homepage it says to add count=”on”, but that adds the number to
   the FB comments.
 * That wasn’t what I wanted.
 * My question is – can I get back just the number of the comments (without displaying
   the comments)?
 * Thanks
 *  [Alex Moss](https://wordpress.org/support/users/alexmoss/)
 * (@alexmoss)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164407)
 * You should actually insert the HTML directly like so:
 * `<span class="fb-comments-count" data-href="http://example.com/"></span>`
 *  Thread Starter [akehat](https://wordpress.org/support/users/akehat/)
 * (@akehat)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164430)
 * I tried
 *     ```
       <span class="fb-comments-count" data-href="<?php the_permalink(); ?>"></span>
       ```
   
 * but getting a consistent **0** – even when there are comments.
 * The outcome is (e.g.):
 *     ```
       <span class="fb-comments-count fb_comments_count_zero" data-href="http://breaking911.com/fifa-gave-lots-of-money-to-the-clinton-foundation/" fb-xfbml-state="rendered" data-iceapw="1" data-iceapc="1"><span class="fb_comments_count" data-iceapw="1">0</span></span>
       ```
   
 * Note the _**fb\_comments\_count\_zero**_ class that was added. Why is that?
 * Thanks
 *  [Alex Moss](https://wordpress.org/support/users/alexmoss/)
 * (@alexmoss)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164432)
 * Your code is correct. However, I entered the URL manually here:
    [https://developers.facebook.com/docs/plugins/comments](https://developers.facebook.com/docs/plugins/comments)
 * and it should me 0 comments. I then commented and see 1 comment (mine):
    [http://www.mgb-restauratie.nl/rotatiebrug-aangeschaft/?fb_comment_id=295178973939783_295548673902813](http://www.mgb-restauratie.nl/rotatiebrug-aangeschaft/?fb_comment_id=295178973939783_295548673902813)
 *  Thread Starter [akehat](https://wordpress.org/support/users/akehat/)
 * (@akehat)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164433)
 * I see what your saying.
    I did now the same, and the number grew. But when I 
   went to the actual page – the comments did not appear. Also – adding a FB comment
   on the page (via the FB plugin) – did not affect the count. What’s happening?
 * Thanks
 *  [Alex Moss](https://wordpress.org/support/users/alexmoss/)
 * (@alexmoss)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164435)
 * If I go to [http://www.mgb-restauratie.nl/rotatiebrug-aangeschaft/](http://www.mgb-restauratie.nl/rotatiebrug-aangeschaft/)
   all I see is the comment I made before. It works a it should. What am I missing?
 *  Thread Starter [akehat](https://wordpress.org/support/users/akehat/)
 * (@akehat)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164439)
 * [http://breaking911.com/elderly-woman-arrested-after-22-hour-standoff-shooting-at-police-robot/](http://breaking911.com/elderly-woman-arrested-after-22-hour-standoff-shooting-at-police-robot/)
 * There’s 3 comments that I just put in.
 * but on the homepage link (on [http://breaking911.com/](http://breaking911.com/)
   right sidebar – 70-Year-Old Woman Shoots at Police Robot During Standoff) it 
   says 2 comments (which I put in yesterday on [https://developers.facebook.com/docs/plugins/comments](https://developers.facebook.com/docs/plugins/comments)…)
 * <span class=”fb-comments-count” data-href=”[http://breaking911.com/elderly-woman-arrested-after-22-hour-standoff-shooting-at-police-robot/”></span&gt](http://breaking911.com/elderly-woman-arrested-after-22-hour-standoff-shooting-at-police-robot/”></span&gt);
 *  Thread Starter [akehat](https://wordpress.org/support/users/akehat/)
 * (@akehat)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164454)
 * Here’s another one:
    [http://breaking911.com/breaking-atlanta-city-hall-evacuated/](http://breaking911.com/breaking-atlanta-city-hall-evacuated/)
   On the page there’s one FB comment.
 * When I go to: [https://developers.facebook.com/docs/plugins/comments](https://developers.facebook.com/docs/plugins/comments)
   
   and enter that link, no comment comes up.
 *  [Alex Moss](https://wordpress.org/support/users/alexmoss/)
 * (@alexmoss)
 * [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164455)
 * I see 2 comments on the first link and 1 on the second, which correlates to what
   the official FB Comments page says.

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘getting just the count’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/facebook-comments-plugin_577794.svg)
 * [Facebook Comments](https://wordpress.org/plugins/facebook-comments-plugin/)
 * [Support Threads](https://wordpress.org/support/plugin/facebook-comments-plugin/)
 * [Active Topics](https://wordpress.org/support/plugin/facebook-comments-plugin/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/facebook-comments-plugin/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/facebook-comments-plugin/reviews/)

## Tags

 * [Comments](https://wordpress.org/support/topic-tag/comments/)
 * [count](https://wordpress.org/support/topic-tag/count/)

 * 10 replies
 * 2 participants
 * Last reply from: [Alex Moss](https://wordpress.org/support/users/alexmoss/)
 * Last activity: [11 years ago](https://wordpress.org/support/topic/getting-just-the-count/#post-6164455)
 * Status: resolved