Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Facebook Login with another account from iOS app

I'm developing an iOS app that integrates with Facebook SDK. When I make the login for the first time with my facebook account it takes the following steps:

  1. Jump to safari web login
  2. Insert my credentials
  3. After that I authorize the permissions that are requested
  4. And then I go to the main menu of my application.

When I press the logout button, I run the following code:

- (void)logout {
     [FBSession.activeSession closeAndClearTokenInformation];
}

With this code I can invalidate the session and clear the access token information. However, when i try to login again, my application jumps to safari web login and my account appears already as logged in (next picture).

Already logged in!

If I want to login with another Facebook account, i can't do it. In other words, I would like to follow the steps that I said earlier or have a mechanism like "Not you?" that Facebook official app provides.

Any idea that what I have to do?

like image 545
Tiago Pereira Avatar asked Dec 10 '13 01:12

Tiago Pereira


People also ask

Can I use 2 Facebook accounts on my iPhone?

It's against the Facebook Community Standards to maintain more than one personal account.

How do I change my default Facebook account on my iPhone?

Go to Settings->Facebook (You will need to scroll down some way) and then tap your account name, then tap on 'Delete Account' you can now enter details of another account. This doesn't apply if you are using the Facebook App from the App store on your device, this is only for the built-in Facebook integration in iOS.


1 Answers

You're still logged in through Safari. Log out there (or clear your cache).

like image 102
user688518 Avatar answered Oct 03 '22 11:10

user688518



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!