Integration of Facebook API in Rails Application

To Integrate Facebook API into Rails with yml file 

1.)Sign in to your fb account

2.)Type developer.facebook.com in url .

3.)Go to App->Register as a developer.
4.) Now again go to app->add a new app->select which platform are you working on for ex:(website)->enter the name of your app->choose a category->create App id.

5.)After this you will get this 'Setup the Facebook SDK for JavaScript' copy the code to notepad for now.

6.)enter the website url you do have if you don't have any url type example.com

7.)After this you will see four options share login social plugins add

8.)Click any of the option which you want in your app for ex: you clicked on Share.

9.)Then read it for your better understanding to the API.

10.)Now again go to your app from app->your app name

11.)enter the display name anything which you like 

12.)enter the mail id of yours for contact

13.)Now copy the app id and secret key and then create a yml file in your app for ex: facebook.yml  and paste their for each enivornment  in config/facebook.yml

14.)create a  initializer file which will load your fb app id and secret key in config/initializer/facebook.rb

15.)Now put the previously copied code of SDK JS with FB.ui in the file where you want your facebook api to be appeared.
16.)To run it on localhost:3000 you need to change the /etc/hosts file go to terminal->sudo su->gedit /etc/hosts-> 127.0.0.1  example.com


Comments

Popular posts from this blog

Installing Wowza Streaming Engine on ubuntu

Highcharts with grouped categories

Completely Uninstall and Install Rubymine on ubuntu