So today, I created a test app in Facebook. I followed the wizard. It told me to add this code right after . I see sdk.js in my console, it gets loaded fine.
<script>
window.fbAsyncInit = function() {
FB.init({
appId : '1xxxxxxxxxxxxxxx',
xfbml : true,
version : 'v2.2'
});
};
(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/sdk.js";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
</script>
Then it also told me to add this code somewhere in the body.
<div class="fb-like" data-share="true" data-width="450" data-show-faces="true"></div>
However, I'm getting this error
Uncaught SecurityError: Blocked a frame with origin "https://s-static.ak.facebook.com" from accessing a frame with origin http://www.ourdomain.com. Protocols, domains, and ports must match.
I've followed other solutions I found earlier on this site but none of them helped.