erivello / facebook-service-provider
A Facebook service provider for Silex.
dev-master
2013-01-21 10:04 UTC
Requires
- php: >=5.3.3
- facebook/php-sdk: dev-master
- silex/silex: 1.0.*
Suggests
- silex/silex: for the integration with your silex application
This package is auto-updated.
Last update: 2025-03-27 22:34:03 UTC
README
A Facebook Service Provider for Silex.
Installation
Installation is very easy, it makes use of Composer.
Install Composer
Run this in your command line:
$ curl -s http://getcomposer.org/installer | php
Or download composer.phar into the project root.
Add FacebookServiceProvider to your composer.json
"require": {
"php": "> 5.3.3",
"erivello/facebook-service-provider": "dev-master"
}
Install Dependencies
Run the following command:
$ php composer.phar install
Now FacebookServiceProvider is installed into your vendor directory.
Registering
$app->register(new Erivello\Silex\Provider\FacebookServiceProvider(), array(
'facebook.apps' => array(
'application one' => array(
'facebook.app_id' => '12345',
'facebook.secret' => '67890'
),
'application two' => array(
'facebook.app_id' => '54321',
'facebook.secret' => '09876'
),
)
));
Usage
You can access the FacebookServiceProvider by calling $app['facebook']
.
Tests
$ php composer.phar install && phpunit
License
The FacebookServiceProvider is licensed under the MIT license.