Facebook Login for website
You can use facebook login in your websites to allow users to login using their facebook account.you don’t need an extra registration and user management for your sites.you can also manage users in your facebook application page.This tutorial will guide you through integrating the social media site (Face book) into you website using Facebook PHP SDK with an example .
Steps for Facebook login for websiteCreate Facebook APP ID and APP secret . Step 1 »
- Goto https://developers.facebook.com/apps/ and Click Add a New App .
- Choose Website
- Choose Name for you App and Click Create New Facebook App ID
- Choose a category for you App and click Create App ID
- Now Click Skip Quick Test
FacebookSession::setDefaultApplication( 'your app ID','your app secret' );Enter your redirection url to which the user should come after login through the facebook .
$helper = new FacebookRedirectLoginHelper('Enter your url' );where rest of the code remain the same. Now when you login through the face book a dialog box like below will be displayed(if you are already logged-in else first login to facebook .) Clicking okay will login you in to the website through facebook