EOAuth2Service::getAccessToken PHP Method

getAccessToken() protected method

Returns the OAuth2 access token.
protected getAccessToken ( string $code ) : string
$code string the OAuth2 code. See {@link getCodeUrl}.
return string the token.
    protected function getAccessToken($code)
    {
        return $this->makeRequest($this->getTokenUrl($code));
    }

Usage Example

コード例 #1
0
ファイル: VKontakteOAuthService.php プロジェクト: RSol/yupe
 protected function getAccessToken($code)
 {
     $result = parent::getAccessToken($code);
     $this->setState('uid', $result->user_id);
     return $result->access_token;
 }