This article give highly proper code
1: Include the JavaScript SDK on your page once, ideally right after the opening
<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";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
2: Place the code for your plugin wherever you want the plugin to appear on your page.
<div class="fb-like" data-send="true" data-width="450" data-show-faces="true"></div>
1: Include the JavaScript SDK on your page once, ideally right after the opening
<body>
tag.<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";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
2: Place the code for your plugin wherever you want the plugin to appear on your page.
<div class="fb-like" data-send="true" data-width="450" data-show-faces="true"></div>
No comments:
Post a Comment
If any doubt?then please comment in my post