I have been trying to get the Facebook SDK to work with Codeigniter but it's just not working. I've Googled the problem for about 8 hours now so I've finally given in and come here.
1) I placed the facebook.php, base_facebook.php and the .crt files inside my application/libraries folder.
2) I created a controller to handle all Facebook API methods for my future Ajax integration.
3) I loaded the library into the constructor of my new controller.
This is the error I'm getting.
An Error Was Encountered
Unable to load the requested class: Facebook
My controller class looks like this.
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Fbapi extends Base_Controller {
public function __construct()
{
parent::__construct();
}
public function index() {
$this->load->library('facebook', $this->config->item('fb_api'));
}
}
All off my library filenames are lowercase and the the class names are UCFIRST.
I tried making a new library called test_library that echoed a response to the browser and this works perfectly fine so I'm really stumped as to why my Facebook libraries aren't being loaded...
Thank you in advance.