Problem adding facebook like & share button

1
Hi guys, was trying to add a like & share button into our app but got a lil stuck. following the 3 steps provided by Fb did not help, Step 2: Include the JavaScript SDK on your page once, ideally right after the opening <body> tag. --> Yes I did <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/nl_NL/sdk.js#xfbml=1&version=v2.6"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));</script> Stap 3: plaats deze code waar je de plug-in op je pagina wilt laten verschijnen. --> Yes I did with using a HTML snippet widget, with no result <div class="fb-like" data-href="http://www.your-domain.com/your-page.html" data-layout="standard" data-action="like" data-show-faces="true"> </div> is it wrong to include the javascript sdk in main - theme- index file?
asked
2 answers
3

I think you also need to call this parse function after the HTML is rendered. Hopefully this works...

answered
0

Hi Marcus, thanx for the info, but I have no idea how to include and parse this code at all...therefore these questions:

1 - Should I add a new script in the body of index.htm?

<div id = "parse"></div>
      <script>FB.XFBML.parse();</script>

2 - Should I - by using the HTML widget- call like these:

<div class="fb-like parse" data-href="https://www.facebook.com/rapido/" data-layout="box_count" data-action="like" data-show-faces="true" data-share="true"></div>
answered