Refused to display 'https://www.facebook.com/' in a frame because it set 'X-Frame-Options' to 'DENY'.
Opened this issue · 2 comments
paramsinghvc commented
When I logout of my Facebook page in another tab on the same browser and then I try to logout of my angular app it gives me this error
Refused to display 'https://www.facebook.com/' in a frame because it set 'X-Frame-Options' to 'DENY'.
But if I'm logged in into facebook and then logout it works fine.
How can I detect an event that is triggered when the user logs out from fb in another tab?
Deleted user commented
You need to add your website url in facebook developer admin ... get into facebook dev platforma chose your aplication and go to settings ... on the bottom add a web platforma and type there your domain .... that thing helped me to erase the console error ..
ntduoc commented
Use script
<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 = "https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v3.0";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
Instead of
`<div id="fb-root"></div>
<script async defer crossorigin="anonymous" src="https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v11.0&appId=xxxxxxxxxxxxx&autoLogAppEvents=1" nonce="PZP7X1PT"></script>`