Creating a custom Facebook login form

让人想犯罪 __ 提交于 2020-01-05 05:33:08

问题


Does anyone know if it is possible to create our own user interface for Facebook connect instead of having to use FBLoginDialog?

If YES, how?

IF NO, can I format FBLoginDialog to have the look that I want just like the FBStreamDialog (POST message to wall)?

Any suggestion would be highly appreciated.


回答1:


The FB authorization process is based on OAuth, and the whole idea is that users should never have to give you their user name or password. If you implement your own login interface, that means all information users type in is passed through your code, and that would mean that you break the intention of OAuth, even if you could get it to work (which is not very easy).

An alternative is to modify the appearance of the page by running some Javascript code on the FB web page after it has been loaded from the network. (You'd do that using -[UIWebView stringByEvaluatingJavaScriptFromString]) But even though this is possible, like taskinoor I don't think it's a good idea, because the main thing is that users should feel confident that it the FB page and nothing else that they are typing their info into.

It's in fact not possible for iPhone users to be sure that you haven't faked the whole web view, but at least you shouldn't try to make them suspicious.




回答2:


I'm not sure whether it can be done or not. But the thing is you most probably should not try to change this. The reason is many user (including me) won't put password if the login page is not from FB. Though I agree that this decision is highly depended on the designer.



来源:https://stackoverflow.com/questions/3246230/creating-a-custom-facebook-login-form

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!