<%= output_once :facebook do %>
<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1<%= raw('&appId=' + options[:app_id]) unless options[:app_id].empty? %>";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<% end %>

<fb:like
  <%= html_attributes(options.slice(:url, :send, :layout, :show_faces, :width, :action, :font, :colorscheme, :ref)) %>
></fb:like>
<%= output_once :facebook do %>
<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1<%= raw('&appId=' + options[:app_id]) unless options[:app_id].empty? %>";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<% end %>

<div class="fb-like"
  <%= html_attributes(options.slice(:url, :send, :layout, :show_faces, :width, :action, :font, :colorscheme, :ref), :data => true) %>
></div>

Switch to the HTML5 version of the Facebook like button
Switch to the HTML5 version of the Facebook like button
