public function login($loginDuration = 0)
    {
        $loginStatus = Yii::$app->getUser()->login($this, $loginDuration);
        if ($loginStatus) {
            $this->trigger(User::EVENT_LOGIN);
        }
        return $loginStatus;
    }
public function login($loginDuration = 0)
    {
        $loginStatus = Yii::$app->getUser()->login($this, $loginDuration);
        if ($loginStatus) {
            $this->trigger(User::EVENT_LOGIN);
        }
        return $loginStatus;
    }
public function login ( $ loginDuration = 0 ) { $ loginStatus = Yii :: $ app -> getUser ( ) -> login ( $ this , $ loginDuration ) ; if ( $ loginStatus ) { $ this -> trigger ( User :: EVENT_LOGIN ) ; } return $ loginStatus ; }
Login user.
@param integer $loginDuration
@return bool true if success
Login user .