Find it
Woody Hayday

Fresh Ideas

Hi there! This is my old blog, I don't hang around here much.
You can now find me trying to mix things up here:
Visit WoodyHayday.com Subscribe To My Email List

Facebook Like button not working or showing 0 likes

Got a facebook like button not working showing zero? Do you wan’t to add a facebook like button to your page that points to a facebook page (fanpage) rather than the page the likebutton is actually on? It is possible but you may have come across this facebook bug that I did.

Scenario’s are either:

  • Use facebook like button generator to generate code for a like button (sometimes even this bugs out..)
  • Use some service like ShareThis to generate code for a facebook like button
And when you stick it on the webpage:
  • It shows as Zero – Facebook likes ‘0’ even if you know that URL (that you installed it on, or fb page) has likes
  • It occasionally shows correct like count, but most of the time shows Zero [0] like’s
Investigate with:
After spending a few hours working out what was causing this 0 like problem on my facebook like button I narrowed it down to two problems people are experiencing:

  1. Error in the code you are copying across. It should be an iframe (unless you are using XFBML) like the code shown on the facebook lint tool (object debugger.) In fact the best way I found was to use the object debugger to make the iframe code and then adapt that using parameters from the facebook like button generator as the likebutton generator bugged out for me. MAKE SURE its pointing to the right url, use https if you can and point it to the page which validates in Lint tool.
  2. Page Problems. If your page doesn’t validate properly in the Lint tool (object debugger) then this is your issue, this is the likely situation if you are seeing it OCCASIONALLY show the right figure in your likes box, but mostly 0 [zero] likes. Page problems as far as I have experienced boil down to:
    1. Facebook soft deleting your page and not telling you. If you are experiencing this ZERO likes situation it might well be that facebook has actually discontinued your page without telling you, leaving it on your admin menu’s and leaving the likes/wall/everything in tact. This is confusing as hell and I wish they would formally tell/make it obvious. Reasons why your page gets deleted? I am sure there are a bunch. I repeat. Your page may look to you to be live, with likes and all – but if you are experiencing zero likes on your like button it might also be deleted. Get your friend to search for it in the search box, if it doesn’t appear, you’ve had it deleted!
    2. Restricted Content. We all love fangating, well its a working economy, but I have a sneaking suspicion it may occasionally cause a discrepancy in like button, potentially pointing a like button to an inaccessible page to the potential like’ee would mean facebook wouldn’t be able to access it and therefore show zero (whereas it might be showing you the proper number as you have access..)
Anyway, for a nice combo of a facebook like button and a google + button (are these going to be more and more important?) check the following code, don’t forget to replace your url ;)
<div align="left" style="height:70px">
    <div id="fbbox" style="float:left;height:65px;width:55px;">
    	<iframe src="http://www.facebook.com/plugins/like.php?href=***YOURURL***&layout=box_count" scrolling="no" frameborder="0" style="height: 65px; width: 55px" allowTransparency="true"></iframe>
    </div>
    <div id="gbox" style="float:left;height:65px;width:55px;"><g:plusone size="tall" href="***YOURURL***"></g:plusone></div>
</div>
This entry was posted in Facebook Pages, Snippets, Social Media, Web Development and tagged , . Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

4 Comments

  1. Ardash
    Posted February 19, 2013 at 1:56 pm

    I was facing the same problem using Sharethis buttons, and found this solution:
    The reason it happened with me is that I had the
    “Measure copy and shares of your website’s content”
    box checked in the Sharethis settings. That adds a code to the URL to track it, so only new likes after that code was added, so Facebook sees it as a new page. When I removed that option, the count went back to the original number. Problem solved!

  2. Posted March 22, 2013 at 2:44 pm

    Thanks for sharing Ardash!

  3. Tony
    Posted January 18, 2014 at 3:45 am

    Dude. I’m really serious: Your article saved my site from embarrassment. I had thousands of likes and was getting a big customer to look at it. My likes were at 0 just before I sent the invite email for some random reason.

    I saw the whole remove sharethis thing and randomly decided to try it. YOU SAVE ME!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

  4. Posted January 24, 2014 at 1:55 pm

    Glad it helped Tony :)

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

Like Festivals?

Got a Project?
A Quote..
"(days) Come and go like muffled and veiled figures, sent from a distant friendly party; but they say nothing, and if we do not use the gifts they bring, they carry them as silently away"
Emerson
© Woody Hayday 2014