Tuesday, 26 October 2010

Adding Facebook comment box to Blogger blog

Facebook is the biggest social network in the world now , it's a great tool for connecting friends and keep update from them .
Many people have an account on Facebook ,and it's very convenient to use Facebook account as a key to comment on a Blogger blog instead of using OpenID ,or a Blogger account . In SimplexDesign blog , I also implemented Facebook comment box as one method for commenting .
facebook comment box

 

Do you want a Facebook comment box on your Blogger blog ? Just follow these steps

1,Go to Facebook developer page ,you will see an interface for creating a new application like this picture bellow :
Enter your site name ,and your site url ( remember to add an slash at the end of url ,like this : http://simplexdesign.blogspot.com/ )
and click on Create application
facebook create application interface

2,Fill the security check ,and it will lead you to a page that provide App id and some Sample Code .
Remember your App ID .Here is my App ID : 124557050936207
facebook application id

3,Go to this page and enter your App ID in Unique Id ,enter the number of comment you want to show in Number of Comments ,and the width of comment box in Width .

facebook comment box option

After that ,click on Get code . You will get a code like that

facebook comment box code
replace APP_ID in the code with the App ID you get from Step 2 ,and then copy the code .

4, Go to Blogger Dashboard ,continue to Design and then Edit HTML ,check on Expand Widget Templates .

5,-If you want Facebook comment box appear right after your post ,find this line
<p><data:post.body/></p>

-If you want to place it on top of regular comments ,find this line :
<b:includable id='comments' var='post'>

And paste the code from step 3 right after one of two lines above ,depend on where you want Facebook comment box show .

Save template and you are done .
Check your blog for result ^^

10 comments:

  1. very impressive, but how do i remove the blogger comment box, because two comment box does not look good.

    ReplyDelete
  2. @Gadfly : you can unable Blogger comment box in Dashboard - Setting - Comments tab

    ReplyDelete
  3. Hi Admin,

    i add this to my blog, i have commented on my blog for test, it should show to my facebook profile but it didn't.

    please help me out.

    ReplyDelete
  4. hi Admin,

    where went wrong? please advice.

    ReplyDelete
  5. i cant add Friends Connect
    Followers gadget to my blog please help me

    ReplyDelete
  6. Hi Huy, tại sao mình làm theo y hệt hướng dẫn mà không thấy nó xuất hiện nhỉ? Mình sử dụng template của bạn tại trang này http://www.8bongda.com .À không hiểu mình làm gì mà cái chỗ hiển thị ảnh từ Flickr nó lỗi. Hiếm khi thấy nó xuất hiện. Huy có thể view source trang mình rồi chỉ cách khắc phục giúp mình được không.
    Thanks.

    ReplyDelete
  7. Dưới đây là ảnh chụp màn hình trang BÓNG ĐÁ 8 chiều nay, mấy tháng nay mới thấy nó hiện ảnh chỗ Flickr (hiện 1 lần rồi thôi, giờ lại biến mất :D)

    http://img7.imageshack.us/img7/1450/flickrlucloiluckhong2.png
    http://img209.imageshack.us/img209/3338/flickrlucloiluckhong.png

    @Ở trên trang demo của mình thì ảnh vẫn hiển thị, lúc thêm script mình rất cẩn thận nên không phải do mình xóa nhầm code, có lẽ do nhiều script nên xung khắc như Huy nói. Hic

    Thanks

    ReplyDelete
  8. very interesting, but when i places facebook comment on my sister blog, and in the same time i give the fans page, why it doesn't work? (not shown)

    but when i places one of both, its worked..

    any solution?

    thanks

    ReplyDelete