Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Loading Iframe Facebook (Load denied by X-Frame-Options)

My team is in charge of some difficulties with an app on Facebook. We believe this occurred some error in loading the iframe. We discovered this error through Firebug:

Load denied by X-Frame-Options: https://www.facebook.com/dialog/oauth?client_id=140656472747871&redirect_uri=https%3A%2F%2Fnuvemapps.com.br%2Fci%2Fncupons%2Fhome%2F%3Ffb_source%3Dsearch%26ref%3Dts%26fref%3Dts&state=32e667a3645c047d751d20811d49ef6b&req_perms=email%2C+publish_steram%2C+manage_pages does not permit framing.

This happens mainly with people who have not allowed the app, so we do not know specifically where this problem is starting. We still have three possible causes left:

  • Server Configuration
  • Problem with our coding
  • Or in our setup facebook app dev

Can anyone help in identifying this error?

Here is the link to the app: https://apps.facebook.com/cupomigo

like image 816
Diogo Souza Avatar asked Feb 16 '13 21:02

Diogo Souza


People also ask

What does X-Frame-Options deny mean?

X-Frame-Options:DENY is a header that forbids a page from being displayed in a frame. If your server is configured to send this heading, your sign-on screen will not be allowed to load within the embed codes provided by Credo, which use the iframe HTML element.

How do I ignore X-Frame-options?

If you want to load a other website into an iFrame and you get the Display forbidden by X-Frame-Options” error then you can actually overcome this by creating a server side proxy script. This by passes the block, because it is just a GET request that might as wel have been a ordinary browser page visit.


1 Answers

I used target="_top" for the link, and it is now working perfectly.

like image 71
Altaf Hussain Avatar answered Nov 03 '22 18:11

Altaf Hussain