Open guilhermelirio opened 7 years ago
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:
Someone to help me?
I'm having this issue too.
Apparently file:// URL is not valid...
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.
'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!