How to Use the Facebook API with Codeigniter

This post shows you how to get the sample Facebook application working with the CodeIgniter framework. For PHP Facebook has an PHP Facebook API and it is located on github. This library gives the php developer much more intuitive access to the facebook api methods and entities.

Download Facebook PHP API ?

To Download Facebook PHP SDK (v.3.2.3) click here
To Download Facebook PHP SDK (v.4) click here

Getting Started

So, let’s get started with your first Facebook application written with CodeIgniter. By the end of it, you’ll have everything you need to create a Facebook application.

1. Download CodeIgnier Framework and Install it. if you install currently , You should see the generic message, “Welcome to CodeIgniter!” If you don’t, you’ve missed something along the way. Reinstall CodeIgniter and start over.

2. Go to Facebook.com/developers and set up a new application.

3. now download Codeigniter Facebook SDK library, to download click here

4.copy and place config and library directory in your ci app.

How do I use it?

You can load the facebook sdk like other libraries in Codeigniter , but you need to set config values in config/facebook.php , Enter your app ID and secret code there.

That’s it your done!.

I hope you like this Post, Please feel free to comment below, your suggestion and problems if you face - we are here to solve your problems.

Arjun
I am Arjun from Hyderabad (India). I have been working as a software engineer from last 7+ years, and its my passion to learn new things and implement them as a practice. Aside from work, I likes gardening and spending time with pets.
DMCA.com Protection Status