我已将Facebook Connect SSO实施到我的网站http://pocketly.com/login ,它似乎适用于所有桌面浏览器。 但由于某种原因,它无法在我的iPhone上运行,我已尝试使用Mobile Safari和Mobile Chrome,它所做的就是打开Facebook auth页面,然后就死了。 我第一次登录浏览器时它正确验证然后关闭窗口,然后窗口又回到我的网站,但似乎没有调用回调。 每次我试着称之为它只是在Facebook网站上以白色屏幕死亡。 我正在使用带有FB.login函数的Javascript SDK。 我不知道还能做什么或如何调试它,我甚至尝试过在新的ios6移动游猎中使用网络检查器。 如果有人有任何建议请告诉我,如果您想查看一些代码示例或了解更多信息,我将很乐意分享。 我也做了一些研究,这里有一些类似的问题没有答案:
Facebook JS SDK无法在Safari上运行 Facebook JS SDK未在Safari Mobile上加载(使用iPad) Facebook FB.login适用于Safari,但不适用于移动Safari
I have implemented Facebook Connect SSO to my website at http://pocketly.com/login and it seems to work across all Desktop browsers. But for some reason it does not work on my iPhone, I have tried with both Mobile Safari and Mobile Chrome and all it does is open up the Facebook auth page and then dies. The first time i log in on the browser it authenticates correctly then closes the window which in turn goes back to my website, but it doesn't seem like the callback is being called. Every other time i try to call it it just dies on Facebook website with a white screen. I am using the Javascript SDK with the FB.login function. I don't know what else to do or how to debug it, i have even tried the web inspector on the new ios6 mobile safari. If any one has any suggestions please let me know, if you would like to see some code examples or know more information i would be happy to share. Also i did some research and here are some similar questions with no answers:
Facebook JS SDK Not Working On Safari Facebook JS SDK not loading on Safari Mobile (using iPad) Facebook FB.login works in Safari, but not mobile Safari
最满意答案
事实证明JS SDK似乎在移动safari上有问题,我也在其他网站上遇到过这个问题。 我最终做的是使用PHP SDK,它涉及重定向而不是尝试通信的窗口。 事实证明这种方法更容易。 任何有JS SDK问题的人都应该先试用PHP。
It turns out that the JS SDK seems to have a problem on mobile safari, i ran across this problem on other sites as well. What i ended up doing was using the PHP SDK which involves a redirect instead of the windows trying to communicate. It turns out this approach is way easier. Anyone else with issues with the JS SDK should try the PHP one first.
更多推荐
发布评论