예제 #1
0
 /**
  * Create service
  *
  * @param ServiceLocatorInterface $serviceLocator
  *
  * @return mixed
  */
 public function createService(ServiceLocatorInterface $serviceLocator)
 {
     $me = new \ZendOAuth2\Client\Facebook();
     $cf = $serviceLocator->get('Config');
     $me->setOptions(new \ZendOAuth2\ClientOptions($cf['zendoauth2']['facebook']));
     return $me;
 }
예제 #2
0
 public function getClient()
 {
     $me = new \ZendOAuth2\Client\Facebook();
     $cf = Bootstrap::getServiceManager()->get('Config');
     $me->setOptions(new \ZendOAuth2\ClientOptions($cf['zendoauth2']['facebook']));
     return $me;
 }