Exemple #1
0
 public function init()
 {
     parent::init();
     if (!Yii::app()->request->isAjaxRequest) {
         $this->jsonOutPut(0, Yii::t('default', 'forbiddenaction'));
     }
 }
Exemple #2
0
 public function init()
 {
     parent::init();
     $this->WB_AKEY = zmf::config('weibo_app_id');
     $this->WB_SKEY = zmf::config('weibo_app_key');
     $this->WB_CALLBACK_URL = zmf::config('weibo_app_callback');
     if (!$this->WB_AKEY || !$this->WB_SKEY || !$this->WB_CALLBACK_URL) {
         throw new CHttpException(403, '暂未开放');
     }
     $this->weiboService = new SinaWeibo($this->WB_AKEY, $this->WB_SKEY);
 }
Exemple #3
0
 public function init()
 {
     parent::init();
 }