开发者

Facebook integration in iphone OS 4.0 or later

i am trying to integrate Facebook on my iphone OS 4.0. The problem comes when i try to display dialog box for login. the dialog 开发者_StackOverflowbox loads and then crashes immediately.The same code is working great in IOS 3.1. Please help. Thanx.


I had a similar issue with my iPhone app. Most likely JavaScript is crashing your application.

I worked around this issue by accessing Facebook login site directly via URL: http://graph.facebook.com/oauth/authorize?client_id=YOUR_APP_ID&redirect_uri=http://YOUR_SITE_URL&scope=publish_stream,offline_access&type=user_agent&display=touch

If you open that link in your iPhone app, it'll display a login screen if user is not logged in, or ask for permission to Publish Stream & Offline Access (as directed in scope) and then it'll come back to YOUR_SITE_URL with access_token, which you can later use to communicate with Facebook via Graph API.


There is a lot of issues related to app crashes, you might want to use the debugger and post the problematic codes for review.


Make sure you are running the latest version of the Facebook SDK from Github. And please post the code that is crashing.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜