How to Add a Facebook Like Button or Like Box

The Easiest Way to Add a Facebook Button to Your WordPress Site

In this post, I’ll explain the differences in the Facebook Like Button and the Facebook Like Box. I will also explain the step-by-step process of adding this functionality to your website using WordPress as an example.

Button vs Box

 
The Facebook Like Button is used for visitors of your website to ‘like’ a particular post, page, site or any other criteria a website has to offer. This is done by assigning a URL to ‘like’. Do not confuse this with a ‘Share’ button which allows Facebook users to share a post, video etc. with their Facebook friends.


I am currently using the Socialize plugin on the Ask Adam League that is running on WordPress.

The Facebook Like Button has some great advantages. It allows users of the Facebook community to ‘like’ something which in turn shares that something and broadcasts it out to all of their Facebook friends via their News Feed. Also, this something that they like will remain on their profile for other people to see and visit.

The Facebook Like Box on the other hand allows visitors to ‘Like’ a Facebook Fan Page. It also has other functions such as showing the faces of people on Facebook who like the Fan Page and it can also display the latest post on the Fan Page.

Important:

An interesting note here is that you can use the Facebook Like Button as a Facebook Like Box but only a Facebook Like Box can be used as a Facebook Like Box. This is how it works. In the Facebook Like Box Generator you are prompted to add a Facebook Page URL in the respective field pigeonholing the developer into using the Facebook API strictly for users to ‘like’ a Facebook Page. However, in the Facebook Like Button Generator the user is allowed to add any URL they want. This makes it possible for users to ‘like’ the corresponding page that the developer is suggesting. How a Facebook Like Button can be used as a Facebook Like Box is simple; add a Facebook URL to the URL field and how you are on your way to making a Facebook Like Button that when clicked will allow a Facebook user to ‘like’ your Facebook page. For example, the Ask Adam League currently has a Facebook Like Button on the site. When clicking on this Like Button, the visitor will be Liking the Facebook Fan page for the Ask Adam League. They will also be able to see other friends of theirs that like the Ask Adam League Facebook Fan Page.

How to Add a Facebook Like Button to a WordPress Site

Adding either the Facebook Like Box or Button is very similar so instead of writing War and Peace here I’ll show you the steps for the Like Button.
Notes: These steps include using the code from the Facebook Developers website and not a WordPress plugin as I’ve found many of the plugins to be confusing or very spotty with their functions.
These steps will show you how to add a Facebook Like Box to your WordPress sidebar using a text widget; the simplest way I have found to add the Like Button.

Generate the Code:

  1. Go to the Facebook Like Button generator. This is where you will set the parameters for your Facebook Like Button and generate the code for your WordPress widget.
  2. The first step for generating the code is to get the URL for your page. I will choose to use the Ask Adam League Facebook page in this example since I want my site visitors to ‘like’ my Facebook page. Just visit the page and grab the full URL there and paste it into the ‘URL to Like’ field. (I’ve noticed that Firefox 3 on my Mac did not generate the Like Button example. It wasn’t until I updated to Firefox 4 that this happened).
  3. Select the different parameters for your Like Button such as pixel width and color scheme. You can also toggle on or off Faces which just displays the faces of the users who like your page.Click ‘Get Code’ and you’ll be presented with two different types of code; iFrame and XFBML. XFBML works for me (I’ll let the coder community explain the differences).
  4. Copy the XFBML code.

Insert the Code:

  1. Login to your WordPress CMS and go to ‘Widgets’ under the ‘Appearance’ pulldown on the right.
  2. Here you’ll have all of your widgets available that can be installed in your sidebar. If you don’t know what these do just think of them as little applications that do things on your sidebar.
  3. Grab the ‘Text’ widget and drag-and-drop it to anywhere you want the Facebook Like Button to be with all of your other widgets on the sidebar respectively. (if there is currently a text widget on your sidebar that you would like to install the Facebook Like Box code to with some other code there will be no problem at all).
  4. Crack open the Text widget by clicking on the pulldown. Your text widget will open up exposing the field where you will enter the code.
  5. Paste the code that you copied from the code generator.
  6. Click ‘save’.
  7. Bring up the page(s) that has your new Facebook Like Button to check it out.

Yeah yeah. I know we only have 12 people who like us on Facebook. Give us a sec.
Now anyone that visits your site will be able to like your Facebook Fan page. You can follow these same steps with the Facebook Like Box generator to make a Like Box if you wish.

Send me a comment if you guys have any questions. Good luck!

Note: My first time adding the Like Button it took almost 2 hours for it to show up on my page. Whether it took the Facebook API a million years to work or whatever else was going on I do not know.

11,483 Replies to “How to Add a Facebook Like Button or Like Box”

  1. Hi there! I just wanted to ask if you ever
    have any issues with hackers? My last blog (wordpress) was hacked and I ended up losing several
    weeks of hard work due to no data backup. Do you have any solutions to prevent hackers?

  2. Hey I know this is off topic but I was wondering if you knew of any widgets I could add
    to my blog that automatically tweet my newest twitter updates.
    I’ve been looking for a plug-in like this for quite some time and was
    hoping maybe you would have some experience with something like this.
    Please let me know if you run into anything. I truly enjoy reading your blog
    and I look forward to your new updates.

  3. Your style is really unique in comparison to other people I’ve read stuff from.

    Thanks for posting when you’ve got the opportunity,
    Guess I will just bookmark this site.

    my blog post 1x.com

  4. Thank you a lot for sharing this with all of us you actually understand what you are talking
    approximately! Bookmarked. Please additionally seek
    advice from my web site =). We will have a hyperlink alternate arrangement between us

  5. Usually I do not read article on blogs, however I would like to say that this write-up very pressured me to check out and do it!
    Your writing taste has been surprised me. Thanks, quite great post.

    my webpage … garcinia cambogia best results (Michael)

  6. Also, if you are a messenger that works in Europe, we can prolong cover to CMR you – a have to if you’re are a European courier motorist.

    Here is my web-site – crazy

  7. Thank you for the good writeup. It in reality was a amusement account
    it. Look complex to more introduced agreeable from you! By the way, how can we keep up a correspondence?

    My web site: garcinia cambogia duncan bc; Suzette,

  8. A messenger standards regarding 100k miles per year so you do not need a level to work
    out your fuel bill is visiting be hundreds of pounds weekly.

    Feel free to surf to my weblog – offensive

  9. Wow that was unusual. I just wrote an incredibly long comment
    but after I clicked submit my comment didn’t show up. Grrrr…
    well I’m not writing all that over again. Anyways, just wanted
    to say great blog!

    my site – garcinia cambogia after stopping (Wilfred)

  10. First of all I would like to say superb blog! I had a quick question in which I’d
    like to ask if you do not mind. I was curious to know how you center yourself and clear your mind before writing.
    I have had trouble clearing my mind in getting my ideas out
    there. I do take pleasure in writing but it just seems like the first 10 to 15 minutes are generally lost just trying to figure out how to
    begin. Any recommendations or hints? Appreciate it!

    Here is my blog post … free walking tour stockholm

  11. If the transportation of goods is part of your daily company, despite exactly how large
    or tiny, you need to constantly obtain products en route insurance policy.

    My blog; league

Leave a Reply