How to Add a Facebook Like Button to Your WordPress Website

Facebook and Twitter has been doing amazingly well to acquire maximum web domination. Twitter released a new feature known as “Anywhere Platform,” which allows users to connect to Twitter from anywhere over the web. Soon after this, Facebook also introduced a “Like” button, which has extended its like feature to other sites on the web. If you are reading an interesting blog or you like a web page, you can recommend it to your friends while reading it from the website. It allows your content to display in your customer’s feed, which eventually helps you to increase your social network on Facebook. This feature also helps you in doing word of mouth advertising. For instance, if a user has 150 Facebook friends, and he likes your post then it will be shown to all of his 150 friends. Isn’t it awesome? We are sure you will be restless to add this feature on your webpage right now. In this article, we have described the whole process of adding Facebook like button in your WordPress posts, blogs and sites.

Instructions

  • 1

    Step 1:

    First of all you need to open your single.php in your theme’s folder. Now, copy the below code and paste it inside your post loop.


  • 2

    Step 2:

    It is highly advised to use the XFBML method because it helps you to get in-depth information on your likes. Here is how to do it;


  • 3

    Step 3:

    Once you paste the code, you have completed the process. It will look like as shown in the image given below.

    In order to display the friend icons below the button, then use this parameter;

    show_face=true

    To show the simple button having the count feature and nothing else, then follow this parameter;

    layout=button_count

    In order to change the text from Like to Recommend, follow this parameter;

    action=recommend

Leave a Reply

Your email address will not be published. Required fields are marked *


+ 7 = fifteen