| Start | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| How to add Facebook Login in Android Add below dependencies to your Add below helper class to your utility package: Add below code in Your Activity: Add below code to your |
||||||||||||||
| Create your own custom button for Facebook login Once you first add the Facebook login/signup, the button looks something like: Most of the times, it doesn't match with the design-specs of your app. And here's how you can customize it: Just wrap the original Next, add your custom button in the same The final thing we do is simply convert the click on my custom button to a click on the facecbook button: Great! Now the button looks something like this: |
||||||||||||||
A minimalistic guide to Facebook login/signup implementation |
||||||||||||||
| Setting permissions to access data from the Facebook profile If you want to retrieve the details of a user's Facebook profile, you need to set permissions for the same: You can keep adding more permissions like friends-list, posts, photos etc. Just pick the right permission (opens new window) and add it the above list. Note: You don't need to set any explicit permissions for accessing the public profile (first name, last name, id, gender etc). |
||||||||||||||
| Logging out of Facebook Facebook SDK 4.0 onwards, this is how we logout: For versions before 4.0, the logging out is gone by explicitly clearing the access token: Syntax
Parameters
|
Read Article
https://develop.horje.com/learn/1434/reference