src/ULogin/Init.php
public function setProviders($providers)
    {
        $array = Parser::map($providers);

        // collection data
        if (empty($array['required']) === false) {
            $this->requiredProviders = implode(',', $array['required']);
        }

        if (empty($array['hidden']) === false) {
            $this->hiddenProviders = implode(',', $array['hidden']);
        }

        return $this;
    }
public function setProviders($providers)
    {
        $array = Parser::map($providers);

        // collection data
        if (empty($array['required']) === false) {
            $this->requiredProviders = implode(',', $array['required']);
        }

        if (empty($array['hidden']) === false) {
            $this->hiddenProviders = implode(',', $array['hidden']);
        }

        return $this;
    }
public function setProviders ( $ providers ) { $ array = Parser :: map ( $ providers ) ; // collection data if ( empty ( $ array [ 'required' ] ) === false ) { $ this -> requiredProviders = implode ( ',' , $ array [ 'required' ] ) ; } if ( empty ( $ array [ 'hidden' ] ) === false ) { $ this -> hiddenProviders = implode ( ',' , $ array [ 'hidden' ] ) ; } return $ this ; }
Allows you to add authentication providers in the list of available.

@param mixed $providers as ('provider' => true, 'provider' => false) or string separated by comma
@example <code>
$this->setProviders([
'vkontakte'     =>  true,
'odnoklassniki' =>  true,
'mailru'        =>  true,
'facebook'      =>  true,
'twitter'       =>  false,  // in drop down
'google'        =>  false,  // in drop down
'yandex'        =>  false,  // in drop down
'livejournal'   =>  false,  // in drop down
'openid'        =>  false   // in drop down
]);

$this->setProviders('vkontakte=true,odnoklassniki=true,mailru=true,openid=false');
</code>
@return Init
Allows you to add authentication providers in the list of available .