setup
– domain A = http://www.domainA.com
– domain B = http://www.domainB.com
On domainA I have a html page with this content
...
< iframe src="http://www.domainB.com/fblogin.php" >< br >
...
fblogin.php takes care of logging people in to facebook. Standalone that page works fine. In the iframe it does not.
on facebook in my app settings I obviously have to enter the Site URL to where Facebook will ‘redirect’ after people have authorized the app. I can do only 1 thing: enter my iframeing html page there … but then, (expected) Facebook passes the necessary login parameters (state , etc) to that page , and not to the fblogin.php page that needs it to log in.
Would love to have some ideas.
Coming back here to lightly answer my own question.
In the end I opted to use the Javascript SDK to log in (through a popup) / following the example on FB dev (https://developers.facebook.com/docs/reference/javascript/).
Had no issues whatsoever after I made that choice.
As an extra measure to overcome the IE8 issue I was having, I ended up putting the following line in the header of my index.php to overcome a possible Privacy Issue in IE8 causing for problems. (you can see that by the little “eye” icon in the bottom toolbar when IE8 thinks something is not ‘right’ with the content of an iframe.
header('p3p: CP="NOI ADM DEV PSAi COM NAV OUR OTR STP IND DEM"');