开发者

Database Design for Facebook Connect Website?

I'm creating a database for a site that uses Facebook connect for user login/profiles.

I usually have a unique key (auto-increment) for all users. I开发者_如何学JAVAs this still a good idea, even if every record (user) is going to have a unique Facebook id that I can use?

Why?


No. It's usually not a good idea even if you're not using Facebook Connect. But since Facebook Connect offers a stable, simple, unique identifier, you should use it. They're doing all the hard work--stand on their shoulders.


If you are going for a single FB id login, then you are fine with they uid that they provide. If you are planning (not necessarily now) to have your own users and also allow a login through FB Connect, then I recommend you to use two tables.

You can always match a FB user and your own users with the email that they provide you into your site and the email that they use for FB.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜