简体   繁体   中英

iOS Facebook SDK: which login system is better?

I am developing a iOS application which allows users to login by using their Facebook account.

I managed to implement the login procedure thanks to official tutorial I found here https://github.com/facebook/facebook-ios-sdk . I found here https://developers.facebook.com/docs/tutorials/ios-sdk-tutorial/authenticate/ another tutorial which looks pretty different since in the first tutorial the user signs in through Safari, instead in the second tutorial the native Facebook App is used.

Among these two systems, which one is better? Perhaps by using Safari I could avoid any issue concerning back compatibility with older versions of iOS?

Thanks!

If you're using the official Facebook SDK, here's what happens:

  • If a user does have the Facebook app installed, they'll be taken to it to authenticate and login to your app.

  • If the user does not have the Facebook app installed, they'll be taken to Safari to authenticate and login to your app.

Either way, the login process is the same. After they authenticate, they're returned to your app using a specific URL scheme so that you can continue with what you're doing.

Finally, if you're targeting iOS 6 only, you can take advantage of the single sign on features built into iOS. Check the docs for more information on that.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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