Widget:FacebookPlugin: Difference between revisions

From Jcastle.info
(Created page with "<noinclude>__NOTOC__ This widget allows you to embed a '''[https://developers.facebook.com/docs/plugins/page-plugin Facebook Page Plugin]''' (iframe version) on your wiki page...")
 
No edit summary
Line 1: Line 1:
<noinclude>__NOTOC__
<div id="fb-root"></div>
This widget allows you to embed a '''[https://developers.facebook.com/docs/plugins/page-plugin Facebook Page Plugin]''' (iframe version) on your wiki page.
<script>(function(d, s, id) {
Adapted by [[User:Alianin|Alianin]] from the [[Widget:Facebook Like Box|Facebook Like Box]] widget by [[User:Chris White|Chris White]].
  var js, fjs = d.getElementsByTagName(s)[0];
==Copy to your site==
  if (d.getElementById(id)) return;
To use this widget on your site, just install the [https://www.mediawiki.org/wiki/Extension:Widgets Widgets] extension and copy the [{{fullurl:{{FULLPAGENAME}}|action=edit}} full source code] of this page to your wiki as '''{{PAGENAME}}''' article.
  js = d.createElement(s); js.id = id;
</noinclude>
  js.src = 'https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.11&appId=261403703876166';
<includeonly><iframe src="//www.facebook.com/plugins/page.php?href=<!--{$profile}-->&amp;tabs=<!--{$tabs}-->&amp;width=<!--{$width|default:340|escape:'urlpathinfo'}-->&amp;height=<!--{$height|default:130|escape:'urlpathinfo'}-->&amp;small_header=<!--{$small_header|default:false|escape:'urlpathinfo'|validate:'boolean'}-->&amp;adapt_container_width=<!--{$adapt_width|default:true|escape:'urlpathinfo'|validate:'boolean'}-->&amp;hide_cover=<!--{$hide_cover|default:false|escape:'urlpathinfo'|validate:'boolean'}-->&amp;show_facepile=<!--{$faces|default:false|escape:'urlpathinfo'|validate:'boolean'}-->&amp;appId" width="<!--{$width|default:340|escape:'urlpathinfo'}-->" height="<!--{$height|default:130|escape:'urlpathinfo'}-->" style="border:none; overflow:hidden;" scrolling="no" frameborder="0" allowTransparency="true"></iframe></includeonly>
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<div class="fb-page" data-href="https://www.facebook.com/Jcastle.info/" data-tabs="timeline" data-small-header="true" data-adapt-container-width="true" data-hide-cover="false" data-show-facepile="false"><blockquote cite="https://www.facebook.com/Jcastle.info/" class="fb-xfbml-parse-ignore"><a href="https://www.facebook.com/Jcastle.info/">Jcastle: Guide to Japanese Castles</a></blockquote></div>

Revision as of 15:24, 13 January 2018

<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 = 'https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.11&appId=261403703876166';
 fjs.parentNode.insertBefore(js, fjs);

}(document, 'script', 'facebook-jssdk'));</script>

<a href="https://www.facebook.com/Jcastle.info/">Jcastle: Guide to Japanese Castles</a>