Contents
Facebook officially deprecated the share button in favor of the like button earlier this year. A few days ago, I realized that the share button no longer displays on sites I manage. Trying to figure out what could be wrong, I checked those sites using a different browser and it was the same. Still in doubt, I used a different PC and even checked other websites just to be sure.
Across the web, a certain version of Facebook share button stopped working. The Share Button has been deprecated already a while ago but not yet completely dead. If it stops working on your website or blog, you only need to update your code.
Facebook deprecated the Share button on February 28, which means they no longer recommend its use in applications or on external web sites. Also, a certain version of Facebook share button was deprecated several years ago, and Facebook switched to serving the new JS SDK in its place on Monday, July 16. Perhaps the old one will be brought back to life later, but then I guess it’s time to upgrade to the new version. Support has already been dropped for it so there’s no point complaining to Facebook.
I prefer using the share button because it lets me share to my fan pages, unlike the like button which Facebook now favors. I found three fixes to this which I think should do the trick.
1. Using the official JD SDK version
– Search for <html, leave a space and add xmlns:fb=”http://ogp.me/ns/fb#” just after it. The resulting code should lok like this:
If this is already there, you don’t need to do it again.
– In the body of your website where you want the code to display, paste this:
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_US/all.js#xfbml=1&appId=YOUR_APP_ID"; // appId must be valid
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<fb:share-button type="box_count">
</fb:share-button>
Hey, make sure you change these parameters for the code to work:
*** YOUR_APP_ID – You must create a facebook application for this code to work. Don’t know how? I explained it on steps 1 and 2 of this post.
*** You can change box_count to button_count if you want a smaller button instead of the large one with counter.
You can use the demo above to see its perfectly working, you only need to follow the steps and do it right.
If you don’t want to mess around with these codes and just need a quick way to get it done, you can consider using Sharethis share buttons. I think they have a plugin for WordPress and if you’re adding it to your website, you’re allowed to customize the look and feel of the button before generating the code.
Implementing the code isn’t that hard either, you only need to place the right code in the head section and the other one in the body section where you want the share button to appear. See the share buttons displayed below this post? It’s from Sharethis.
If you don’t own a website and only need a way to share any page on Facebook real fast, this is just what you need. Even if the page doesn’t have a share button, you can still share it anyway as you just need to install the share button on your browser.
After you drag the button to the Bookmarks Bar, it will look like this.
Either of these three fixes should get you sharing on Facebook again. Personally, I prefer it to the like button and I wish it’s not being deprecated.