Source of file FacebookCredentialController.php
Size: 1,044 Bytes - Last Modified: 2022-02-21T10:01:15+00:00
/var/www/docs.ssmods.com/process/src/code/extensions/FacebookCredentialController.php
12345678910111213141516171819202122232425262728293031323334353637 | <?php /** * To change this template, choose Tools | Templates * and open the template in the editor. */ class FacebookCredentialController extends Extension { private static $allowed_actions = array( 'FacebookAppId', 'FacebookRedirectUrl', 'FacebookScope', 'FacebookState', ); public function FacebookAppId(){ return FacebookAuthRequest::config()->app_id; } public function FacebookRedirectUrl(){ return FacebookAuthRequest::config()->redirect_url; } public function FacebookScope(){ return FacebookAuthRequest::config()->scope; } public function FacebookState(){ return FacebookAuthRequest::State(); } public function FacebookConnectUrl(){ return "https://www.facebook.com/dialog/oauth?client_id={$this->owner->FacebookAppId()}&redirect_uri={$this->owner->FacebookRedirectUrl()}&state={$this->owner->FacebookState()}&response_type=code&scope={$this->owner->FacebookScope()}"; } } |