简体   繁体   English

Facebook iOS SDK演示应用-URL方案不起作用

[英]Facebook iOS SDK Demo App - URL Scheme won't work

I entered my App-ID (DemoAppViewController.m - Line 25) in the FB Demo App and added the following URL-Scheme in the Info.plist: 我在FB Demo App中输入了我的App-ID(DemoAppViewController.m-第25行),并在Info.plist中添加了以下URL方案:

URL Types -> Item 0 -> URL Schemes -> Item 0 -> fb125014xxxxxxxxx URL类型->项目0-> URL方案->项目0-> fb125014xxxxxxxxx

But everytime I'm trying to login it will redirect me to Safari. 但是每次我尝试登录时,它将重定向到Safari。 What am I missing? 我想念什么?

did you enter your app-id like this to DemoAppViewController.m? 您是否向DemoAppViewController.m输入了这样的应用程序ID?

@"app-id" @“ app-id”

If you do not have the Facebook app installed, then that is the way it is supposed to work. 如果您尚未安装Facebook应用程序,则应采用这种方式。 It will call up Safari to collect the user's login credentials. 它将调用Safari来收集用户的登录凭据。 Then it will return back to the app, the result of that login attempt (success, failed, canceled). 然后它将返回该应用程序,即登录尝试的结果(成功,失败,已取消)。

You can set the tryFBAuth or trySafariAuth settings to NO to disable those, outside mechanisms, in which case a dialog will pop up to collect user email/password. 您可以将tryFBAuth或trySafariAuth设置设置为NO以禁用那些外部机制,在这种情况下,将弹出一个对话框来收集用户电子邮件/密码。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM