Showing posts with label social login. Show all posts
Showing posts with label social login. Show all posts

Thursday, January 30, 2014

PHP - How to Login with Facebook


Login with Facebook


In this tutorial , I will take you through as how can you make an application wherein you login with Facebook.
We will be using Facebook Graph API for this purpose.
You need to follow the below steps to get started.
  1. Visit https://developers.facebook.com/apps and click Create New App.
  2. You will then get an App ID & Secret to be used for your current application.
  3. Download the zip file from  here.Then extract it and copy to your root directory.
  4. Edit config.php and change App ID & Secret to these values.
  5. Also change callback url to have your site path.
  6. Access index.php via your browser.
That’s all when you click on login with facebook button , you will be redirected to Facebook’s login page.After entering your proper credentials , you will be redirected to your site.

You will also have to add a logout button on your web page.However I have written the code in the file to logout.

 

Copyright @ 2013 PHP WORDPRESS MAGENTO .

Designed by Kcon Technosoft