src/OAuth2/ResponseType/AccessToken.php
public function getAuthorizeResponse($params, $user_id = null)
    {
        // build the URL to redirect to
        $result = array('query' => array());

        $params += array('scope' => null, 'state' => null);

        /*
         * a refresh token MUST NOT be included in the fragment
         *
         * @see http://tools.ietf.org/html/rfc6749#section-4.2.2
         */
        $includeRefreshToken = false;
        $result["fragment"] = $this->createAccessToken($params['client_id'], $user_id, $params['scope'], $includeRefreshToken);

        if (isset($params['state'])) {
            $result["fragment"]["state"] = $params['state'];
        }

        return array($params['redirect_uri'], $result);
    }
public function getAuthorizeResponse($params, $user_id = null)
    {
        // build the URL to redirect to
        $result = array('query' => array());

        $params += array('scope' => null, 'state' => null);

        /*
         * a refresh token MUST NOT be included in the fragment
         *
         * @see http://tools.ietf.org/html/rfc6749#section-4.2.2
         */
        $includeRefreshToken = false;
        $result["fragment"] = $this->createAccessToken($params['client_id'], $user_id, $params['scope'], $includeRefreshToken);

        if (isset($params['state'])) {
            $result["fragment"]["state"] = $params['state'];
        }

        return array($params['redirect_uri'], $result);
    }
public function getAuthorizeResponse ( $ params , $ user_id = null ) { // build the URL to redirect to $ result = array ( 'query' => array ( ) ) ; $ params += array ( 'scope' => null , 'state' => null ) ; /*
         * a refresh token MUST NOT be included in the fragment
         *
         * @see http://tools.ietf.org/html/rfc6749#section-4.2.2
         */ $ includeRefreshToken = false ; $ result [ "fragment" ] = $ this -> createAccessToken ( $ params [ 'client_id' ] , $ user_id , $ params [ 'scope' ] , $ includeRefreshToken ) ; if ( isset ( $ params [ 'state' ] ) ) { $ result [ "fragment" ] [ "state" ] = $ params [ 'state' ] ; } return array ( $ params [ 'redirect_uri' ] , $ result ) ; }
Get authorize response

@param array $params
@param mixed $user_id
@return array
Get authorize response