Difference between revisions of "Widget:FBLike"

From WikiVet English
Jump to navigation Jump to search
Line 3: Line 3:
 
To insert this widget, use the following code:
 
To insert this widget, use the following code:
  
  <nowiki>{{#widget:</nowiki>{{PAGENAME}}<nowiki>}}</nowiki></noinclude><includeonly><div id="fb-root"></div><script src="http://connect.facebook.net/en_US/all.js#xfbml=1"></script><fb:like href="http://www.facebook.com/pages/WikiVet/188576847835536?v=wall" send="true" width="200" show_faces="false" font="lucida grande"></fb:like></includeonly>
+
  <nowiki>{{#widget:</nowiki>{{PAGENAME}}<nowiki>}}</nowiki></noinclude><includeonly><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_GB/all.js#xfbml=1";
 +
  fjs.parentNode.insertBefore(js, fjs);
 +
}(document, 'script', 'facebook-jssdk'));</script><div class="fb-like" data-href="http://www.facebook.com/pages/WikiVet/188576847835536?v=wall" data-send="false" data-layout="button_count" data-width="350" data-show-faces="false" data-font="verdana"></div></includeonly>

Revision as of 13:01, 14 October 2011

This allows a Facebook 'Like' button to be embedded into a wiki page.

Usage

To insert this widget, use the following code:

{{#widget:FBLike}}