-1

//I get no errors for my website but still, the Facebook like button doesn't show. //How do I fix this?

    <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 = "http://connect.facebook.net/en_US/sdk.js#xfbml=1&appId=314589238737762&version=v2.0";
            fjs.parentNode.insertBefore(js, fjs);
        }
        (document, 'script', 'facebook-jssdk'));
    </script>
    <div class="fb-like" data-href="http://www.facebook.com/genamoapp" data-layout="standard" data-action="like" data-show-faces="true" data-share="true"></div>

1 Answers1

0

May be a bug with that App or your App is not set up correctly. Make sure it´s set public in the "Status & Review" tab, for example. If i try that code with one of my App IDs, it works fine.

Also, don´t use http, replace the source with this:

js.src = "//connect.facebook.net/en_US/sdk.js#xfbml=1&appId=314589238737762&version=v2.0";

...and try it on a real server, of course. If you want to try it locally, start a webserver on your PC and access the page with localhost.

andyrandy
  • 72,880
  • 8
  • 113
  • 130