0

I want to have sign up/login functionality on my site with a "Login with Facebook" and "Login with Twitter" button.

Considering the following scenario:

  • User A logs in with Twitter.
  • Account gets created.
  • User A logs out.
  • User A comes back next week and can't remember what they signed up with (or just feels like) using Facebook login this time.

How can you combine these accounts?

So far there's 2 options I can think of:-

  • Cookie (Not reliable)
  • Have a 'login' and 'signup' action. So if they 'login' with Facebook it will say "You never signed up for this site with Facebook. Did you maybe use Twitter?" (But maybe they will 'signup' with Facebook then and then I still have no connection with the previous twitter account)

1 Answer 1

2

There's no way to link the two accounts unless the user tells you they should be linked. You're entirely right that a cookie isn't reliable - someone else might be using that computer now.

What you need is a way for a user with an existing account to link their Twitter and/or Facebook account to the account they're currently logged into. Then you detect that you already know about that Facebook login when they try to link it, and offer to merge their data. It's really on the user to remember how they log in to your site, the same way it's on them to remember their passwords.

Scenario:

  • User A comes along and signs up with Facebook
  • Later, User B (who may or not be the same as A) comes along and signs up with Twitter
  • User B decides to link their Facebook account, which you recognize as being the same as User A.
  • You tell the user: "This Facebook account has already been linked to the the system. Is this you?" If so, you merge the accounts in your backend.
1
  • Yeah, that's what I feared. I was hoping someone might have found a solution for this problem. Commented Jun 14, 2013 at 20:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.