Announcement

Collapse
No announcement yet.

Facebook SDK for JavaScript

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Facebook SDK for JavaScript

    Morniing

    i would like to embed a video from Facebook

    To do that you have to:

    1. Include the JavaScript SDK on your page once, ideally right after the opening <body> tag.

    HTML Code:
    <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/es_ES/sdk.js#xfbml=1&version=v2.4";
      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.

    HTML Code:
    <div class="fb-video" data-href="https://www.facebook.com/facebook/videos/10153231379946729/" data-width="500"><div class="fb-xfbml-parse-ignore"><blockquote cite="https://www.facebook.com/facebook/videos/10153231379946729/"><a href="https://www.facebook.com/facebook/videos/10153231379946729/">How to Share With Just Friends</a><p>How to share with just friends.</p>Posted by <a href="https://www.facebook.com/facebook">Facebook</a> on Viernes, 5 de diciembre de 2014</blockquote></div></div>
    My doubt is where I have to add the JavaScript SDK in the website

    Cheers

  • #2
    My doubt is where I have to add the JavaScript SDK in the website
    Try putting that in a hookbox and hook it to genesis_before.

    Comment


    • #3
      Works perfect!

      ​Cheers SiGa

      Comment


      • SiGa
        SiGa commented
        Editing a comment
        Glad to hear!
    Working...
    X