yii\authclient\OpenId::buildAuthUrl PHP 메소드

buildAuthUrl() 공개 메소드

Returns authentication URL. Usually, you want to redirect your user to it.
public buildAuthUrl ( boolean $identifierSelect = null ) : string
$identifierSelect boolean whether to request OP to select identity for an user in OpenID 2, does not affect OpenID 1.
리턴 string the authentication URL.
    public function buildAuthUrl($identifierSelect = null)
    {
        $authUrl = $this->authUrl;
        $claimedId = $this->getClaimedId();
        if (empty($claimedId)) {
            $this->setClaimedId($authUrl);
        }
        $serverInfo = $this->discover($authUrl);
        if ($serverInfo['version'] == 2) {
            if ($identifierSelect !== null) {
                $serverInfo['identifier_select'] = $identifierSelect;
            }
            return $this->buildAuthUrlV2($serverInfo);
        }
        return $this->buildAuthUrlV1($serverInfo);
    }