How to: Add the Facebook 'Like' Button to Wordpress

Facebook have launched a new suite of Social Plugins. The changes are huge and I won’t go into them here, you can check that out on their developers website.

The new ‘like’ button is great for bloggers. It is faster, still allows users to add comments and, according to Facebook, users are more likely to ‘like’ something than share the link (at the end of the day the result is the same, you show up in their feed).

Sadly, the Facebook Developer tool to create Like buttonsĀ  is not as simple as the Share Button for novices. If you are wanting users to be able to like each individual page / post on your website here is how you do it:

Step One: Head to the Like Button area (click here).*

Step Two: When asked for the URL to Like enter <?php the_permalink() ?>; All this does is tells Facebook to like whatever wordpress post, page or website the user is currently on. This will save you generating a new like button for each post you make!

Step Three: Take the code Facebook generates for you and implement it as you would normally into your website. A great place to start is to replace your old ‘Share’ code with the new like code.

I hope this helps. It’s actually quite simple!