示例#1
0
 /**
  * Initialize the component.
  */
 public function init()
 {
     parent::init();
     $host = null;
     if (array_key_exists('openid_return_to', $_GET)) {
         $url = parse_url($_GET['openid_return_to']);
         $host = $url['host'];
     }
     if (empty($host)) {
         $host = Yii::$app->getRequest()->getHostInfo();
     }
     $this->auth = new LightOpenID($host);
 }
示例#2
0
 /**
  * Initialize the component.
  */
 public function init()
 {
     parent::init();
     $this->auth = new LightOpenID(Yii::$app->getRequest()->getHostInfo());
 }