I have already implemented Facebook login with my quickblox application, but I was wondering if there was any way to implement Google login as well? There's nothing on their documentation that would suggest that, but I was just wondering if anyone on here has figured out how to do it? Thanks!
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
QuickBlox doesn't support Google+ out of the box like Twitter and Facebook,
but, anyway, you can implement Google+ login.
For example, you have Google+ email and you would like to use it to login to QuickBlox,
here is what you can do:
NSString *googleEmail = @"";
[QBUsers logInWithUserEmail:googleEmail password:[googleEmail hash] delegate:self];
First time when you do this - this request will fail because you don't have such user.
You need to process this error and create new user:
QBUUser *user = [QBUUser user];
user.email = googleEmail;
user.password = [googleEmail hash];
[QBUsers signUp:user delegate:self];
and then repeat login request.
Fore more info you can refer Users code sample
And you can build password using any algorithm you want, this just an example with hash
make sense?