How to Implement Facebook Comments on Your Webpage

Facebook offers website developers several tools to help them integrate their sites with Facebook. Social plugins such as "Comments," for example, allow users to interact with pages and blog posts using their Facebook accounts -- and, optionally, cross-post their interactions to Facebook. Generate code for a Facebook comments box on the Facebook Developers portal and paste it into your site's HTML or PHP to implement Facebook comments on your website or blog.

Instructions

    • 1

      Sign in to your Facebook account. Click the "Developers" link, located in the lower right corner of the main Facebook page.

    • 2

      Click the "Add Facebook to my Site" button. Click the "Core Concepts" option in the left navigation menu, then click "Social Plugins." Click "Comments."

    • 3

      Input the URL of the page you plan to insert the comments box. Input the desired width of your box in pixels, then click "Get Code." Highlight the code, right-click on it and click "Copy."

    • 4

      Log in to your Web hosting account. Open the HTML or PHP file of the page on which you want to implement comments. Click your mouse at the location where you want the comments box to be, right-click and select "Paste." Save the HTML or PHP file and view the page to make sure the comment box is correctly implemented.

Tips & Warnings

  • If you own a blog and use a single PHP template for all your posts, use the string "<?php the_permalink() ?>" as the URL so that comments users leave on each post go only to the page they're viewing and not to all of them.

Related Searches:

References

Resources

Comments

View all 20 Comments

You May Also Like

Related Ads

Featured