Comments (6)
Looks like the php library is using www.facebook.com/login.php
Is it supposed to be apps or www? Do you have a link to the docs?
from mini_fb.
I'm getting the same thing from the docs. From testing though, apps.facebook.com works properly for canvas/iframe applications, whereas api seems to act more like facebook connect. (It shows a greyed out "authorize this app" page inside the iframe. clicking it opens a new window similar to using facebook connect).
Technically mini_fb has it correct, with the exception that for an iframe/canvas app you need a third url (apps.facebook).
It might be worth noting too that this looks like the "old" way to do things, however the FB docs for the new api don't really provide a lot of information regarding authenticating canvas/iframe apps :) Their docs basically suck unless your using php.
I'll keep looking through the docs to see what I come up with. I tried using some examples from your google groups (which mentioned iframe apps), but kept running into this problem.
from mini_fb.
So do we need another method like canvas_login_url?
from mini_fb.
According to facebook you need the old style url's for canvas/iframe applications for now, which would use the apps.facebook.com path.
From what I'm reading this may change later, but to officially support iframe/canvas urls you would. I'm not sure what the api.facebook.com (since anything outside of facebook should use oAuth) url is used for within the current implementation of login_url, but if the intention was for authentication inside of facebook, for the time being it should point to apps.facebook.com/login.php?v=1.0....
This covers both authorization of the application, as well as requiring users to login to facebook should they navigate directly to your apps.facebook.com/application url.
from mini_fb.
Here is some information that may help:
They mention that you can use oAuth for this, but the oAuth page describes authentication using a connect url, which is setup for websites/applications outside of the facebook iframe/canvas. (I've verified it doesn't work in an iFrame application)
This could also be on Faceboook's end, as they may not have upgraded canvas/iframe apps to properly support oAuth. Their docs are just too scattered to tell :)
from mini_fb.
Ok, looks like this is on Facebook after all, so I'm going to close this out.
You CAN use the oauth_url method to authenticate a canvas/iframe application. The issue is you have to basically use a javascript redirect targeting the "parent" window.
Super ghetto and this is something that you guys definitely can't help. You may want to update your docs and example app though :) I was using that as a reference. Using redirect_to oauth_url will fail inside an iframe or canvas.
Once I work the kinks out I will try to post an example if you'd like. Might help other users in the future.
This link may also help as a reference: http://forum.developers.facebook.com/viewtopic.php?pid=225621
from mini_fb.
Related Issues (20)
- Friends.getAppUsers Bug (REST) HOT 2
- Problem with religion HOT 1
- OpenSSL::SSL::SSLError
- better way to handle facebook allow access? HOT 2
- Publishing checkins
- mini_fb fails if behind proxy
- verify_signed_request error due SHA256 usage of OpenSSL HOT 1
- Batch Publishing
- MiniFB.signed_request_params isn't in the released gem HOT 1
- fql returning long string id gets converted to int and truncated.
- Possible signed_request signature validation error
- Get user photos without limitations
- Fix authenticate_as_app with logging enabled
- Release 2.0.1 HOT 3
- rest client does not connect to graph api using SSLv3 HOT 6
- bug when using split('&') for params_array HOT 2
- missing example mini_fb_tests.yml? HOT 2
- why did you remove the JSON quick fix for things that don't return JSON? HOT 7
- VERSION = "2.2.1" -> bug, body.split HOT 3
- New format of returned data in fb_exchange_token HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mini_fb.