Facebook Recommendations Bar Beta Plugin Makes Your Site More Social

Facebook has released a new beta plugin, dubbed as Facebook Recommendations Bar, which will allow blogs and websites to add more content and recommendations for users to share with family and friends a very good read.

Facebook Recommendations Bar

The Facebook Recommendations Bar gives users a new way to ‘like’ a particular article, receive recommendations, and inform other users about interesting posts.

Facebook, the world’s largest social networking company, made sure that the bar will remain docked on either of the lower corners (left or right) of the screen, regardless of the blog or website. This approach loads a page and shows the Recommendations Bar in collapsed mode. According to the company, users will have the option to ‘like’ a particular page in this view.

After a user finishes reading a post or nears the bottom of the page, the plugin will expand automatically. This view will display a social recommendation of additional content or articles within the website.

Site owners, however, need to add open graph markup on their articles so Facebook understands and customizes how to show the plugin on the site. If not included, an error message will appear, rather than a recommendation on the Recommendations Bar.

facebook-recommendations-bar
Facebook code generator (left) for the Recommendations Bar (right)

Plugin Expansion

Website administrators can expand the plugin after meeting requirements for the trigger parameter. A user needs to stay on the page for a specified time as well, which reflects on the read_time parameter.

The trigger parameter contains three values:

  • onvisible – the plugin expands if a user scrolls past a specified point where the tag, <fb:recommendations-bar />, appears on the HTML page. This is the simplest option that will work best if you place the tag right at the end of your article’s main content. This is the default.
  • X% – where X is any positive integer less than or equal to 100. This specifies the percent of the page the user must scroll down before the plugin expands. For example, 100% will indicate that a user needs to scroll all the way to the end of the page before the plugin expands. 50% will be to the middle of the page.
  • manual – use this option to manually trigger the plugin. When you want to trigger the plugin, callFB.XFBML.RecommendationsBar.markRead(href); in JavaScript. The href parameter is optional. It will default to the current page if not set. If provided, it must match the href parameter on the XFBML tag. The manual trigger is useful when you have more a multi-page article. For example, on a three page article, you would add trigger=”manual” on pages one and two, and never call the markRead JavaScript function on those pages.

The read_time parameter orders the plugin to hold back until it meets a particular amount of time before expansion. It simply takes an integer to represent the number of seconds. By default, this is 30 seconds and minimum time is 10 seconds. Note: trigger must be true and read_time must be met for the plugin to expand.

Attributes

  • href – the URL of the page. The XFBML version defaults to the current page.
  • trigger – When the plugin expands, this parameter is evaluated in addition to the read_time parameter. Default is when a user scrolls past the <fb:recommendations-bar/>tag. There are three options.
    • onvisible – read is published when a user scrolls past the exact point where the XFBML tag is placed on the page.
    • X% – where X is any positive integer less than or equal to 100. Indicates % of page scrolled past before read is triggered
    • manual – use this option to manually trigger the read action. You callFB.XFBML.RecommendationsBar.markRead(href); when you want the plugin to expand. The href parameter is only necessary if the i tag includes an explicit href attribute. By default, this is the current request URL.
  • read_time – The number of seconds before the plugin will expand. Default is 30 seconds. Minimum is 10 seconds.
  • action – The verb to display on the button. Options: ‘like’, ‘recommend’
  • side – the side of the screen where the plugin will be displayed. This will automatically adjust based on the language, or can be set explicitly. Options: ‘left’, ‘right’
  • site – a comma separated list of domains to show recommendations for. The default is the domain of the href parameter.
  • ref – a label for tracking referrals; must be less than 50 characters and can contain alphanumeric characters and some punctuation (currently +/=-.:_). The ref attribute causes two parameters to be added to the referrer URL when a user clicks a link from a stream story about a Like action:
    • fb_ref – the ref parameter
    • fb_source – The stream type (‘home’, ‘profile’, ‘search’, ‘other’) in which the click occurred and the story type (‘oneline’ or ‘multiline’), concatenated with an underscore.
  • num_recommendations – This is the number of recommendations to display. By default, this value is 2 and the maximum value is 5.
  • max_age – a limit on recommendation and creation time of articles that are surfaced in the plugins, the default is 0 (age is not taken into account). Otherwise, the valid values are 1-180, which specifies the number of days.

Website owners and administrators can get their codes for the Facebook Recommendations Bar beta plugin from the code generator found here.

Visit the site regularly. We will provide a sample implementation of the Facebook Recommendations Bar in a blogsite such as Blogger.