My site is built on the zend framework. I have a link on my site that opens an iframe in order for a user to post to twitter. I can load the iframe just fine, but if the user has not yet authorized twitter, the iframe redirects to the twitter authorization page, and then back to my site.
When I test the flow by hitting the page directly that loads into the iframe, everything works fine. However, within the iframe, the redirects do not load, so the iframe is simply a blank page.
My redirect from within the page loaded in the iframe looks like this:
return $this->_helper->redirector->gotoUrl("http://twitter.com/oauth/authorize?oauth_token={$session->token}");
The reason, twitter has disabled this, is that you can't see the address bar in an iframe. So web apps could do easy fishing: telling the user to input his/her twitter user/passw into a form which just looks like the twitter sign in form, but is in fact hosted on the fishing server.
Related
I'm integrating a Facebook Page feed using the Facebook Page Plugin https://developers.facebook.com/docs/plugins/page-plugin
Although it's working fine for almost all pages, I'm having an issue with one Facebook page. The page plugin is displayed but the feed is empty, no post at all.
The page I'm trying to embed:
https://www.facebook.com/ConnectHearingAsheboro/
The web page where the widget is setup:
https://www.connecthearing.com/hearing-clinics/nc/asheboro/
Publications on the page are correctly displayed when on Facebook site, even when being logged out.
Does somebody have an idea of why would that occur ?
Thanks
This is not a bug, it's a feature
Facebook support answered me here https://developers.facebook.com/bugs/1109206649216632/
The Facebook page I'm using in the widget is sharing posts from its parent Facebook page. The Facebook page widget doesn't include the parent page posts, it's just the way it's been built.
It's a dead end.
If you are using a page tab on facebook, you can connect other websites inside the iframe. I want to get the url of facebook within the facebook page. when I am trying to get window.location.url, it shows my website url, how to do it in facebook page to get facebook url
You can't. Your Facebook application exists within an iframe, which cannot access the parent window on facebook.com due to same-origin restrictions in all major browsers. It is effectively sandboxed.
However, the Facebook signed request will include the ID of the Facebook Page your tab is being accessed on.
I am trying to do the Facebook page plugin to a site of mine and anytime I enter my page URL, I get this code from Facebook - Error: Not a valid Facebook Page url.
I am copying and pasting the URL right from my profile page. I tried this on several other of my friends pages and I keep getting the same error. I get this error on the Facebook developer page and on my site.
I am using this:
https://developers.facebook.com/docs/plugins/page-plugin
I went to Social Plugins and then Page plugin. I then typed the URL in the Facebook Page URL input field. It is supposed to show a preview of the page plugin, but I continuously only get the error.
What could I be doing wrong?
profile != page
A user profile and a Facebook page are two different things.
The plugin works for pages only, not for user profiles.
After I installed the iframehost app and edited content. The app how to know my page id and render the content successfully. I want to make an app such as it.
My problem is: Assume many users installed my App for their page, but I don't know how to get the page id from different Iframe for each request the page. Please, who can explain how to get page id from iframe when users enter the Facebook page tab.
You can get the Page ID with the signed_request parameter. Here are some threads where this is explained already:
Facebook API get Fanpage ID inside Page Tab
Get Facebook Page Tab ID of current Tab?
how to get facebook page id inside page fan tab using facebook javascript sdk
How can I find out what Page has installed my Facebook App / which page is loading my app
Our site allows users to register using Facebook Connect. We also have a Facebook page. We'd like to include the "Connect with Facebook" button in our page so a user could instantly connect (aka register) and then be forwarded on to their account on our site.
I was hoping to use the Static FBML page application and the FBML iFrame tag to simply embed the button but it looks like the iFrame tag isn't allowed in Facebook pages. Facebook Connect uses JavaScript so I'm wondering if there is some kind of trick I could use like popping up a page in a new window that would automatically display the connect dialog box.
Any ideas on how I would include a Facebook Connect button on our Facebook page would awesome!
Thanks in advance for your help.
I think the best method would just be a link back to your site (you could even use the Facebook Connect image as the link) to a custom page that triggers the FB.connect javascript that's needed.
Check here for info about FB.connect.requireSession().