Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The redirect_uri URL is not supported! #123

Open
guilhermelirio opened this issue Mar 14, 2017 · 4 comments
Open

The redirect_uri URL is not supported! #123

guilhermelirio opened this issue Mar 14, 2017 · 4 comments

Comments

@guilhermelirio
Copy link

'I'm testing the login from the desktop, and it's giving this error!
The popup link that opens is this:

https://www.facebook.com/dialog/oauth?client_id=XXXXXXXXXX&redirect_uri=file:///C:/Users/SERVIDOR/Desktop/sample/www/oauthcallback.html&response_type=token&display=popup&scope=email

If it is by localhost:8000 (Phonegap Test), it works normally!

oauthcallback.html:
<script> window.opener.openFB.oauthCallback(window.location.href); window.close(); </script>

openfb.js: http://pastebin.com/KsJzNFnN

Where is the error?

Thanks!

@guilhermelirio
Copy link
Author

I`m using JSConsole.com for tests! Return:

Connection established with file:///android_asset/www/login.html Mozilla/5.0 (Linux; U; Android 4.1.2; pt-br; ST27i Build/6.2.A.1.100) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30

Ok, but when I click the login button, it gives the following error:

screenshot_2017-03-14-19-42-19

Someone to help me?

@lf94
Copy link

lf94 commented May 4, 2017

I'm having this issue too.

@lf94
Copy link

lf94 commented May 4, 2017

Apparently file:// URL is not valid...

@josvaler
Copy link

josvaler commented Aug 21, 2017

I wonder to know why you guys are trying to use a local url like

file:///C:/Users/SERVIDOR/Desktop/sample/www/oauthcallback.html&response_type=token&display=popup&scope=email

Of course this is not a valid url, the limitation is because Facebook.

// Default OAuth redirect URL. Can be overriden in init()
oauthRedirectURL = baseURL + '/oauthcallback.html'

where /outhcallback.html depends of baseURL.

baseURL takes the Facebook Settings under "Valid OAuth redirect URIs", in other words this is the expected behavior in my understanding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants