當前位置: 首頁>>代碼示例>>PHP>>正文


PHP BaseController::_initialize方法代碼示例

本文整理匯總了PHP中BaseController::_initialize方法的典型用法代碼示例。如果您正苦於以下問題:PHP BaseController::_initialize方法的具體用法?PHP BaseController::_initialize怎麽用?PHP BaseController::_initialize使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在BaseController的用法示例。


在下文中一共展示了BaseController::_initialize方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: _initialize

 public function _initialize()
 {
     parent::_initialize();
     $json = $_POST['params'];
     $this->params = json_decode($json, TRUE);
     $this->assign('currentnav', '網站設置');
 }
開發者ID:happyxiaod,項目名稱:luobojianzhi,代碼行數:7,代碼來源:SettingController.class.php

示例2: _initialize

 protected function _initialize()
 {
     parent::_initialize();
     $this->mInviteModel = D('Ucenter/Invite');
     $this->mInviteTypeModel = D('Ucenter/InviteType');
     $this->mInviteBuyLogModel = D('Ucenter/InviteBuyLog');
     $this->mInviteUserInfoModel = D('Ucenter/InviteUserInfo');
 }
開發者ID:admpub,項目名稱:OpenCenter,代碼行數:8,代碼來源:InviteController.class.php

示例3: _initialize

 public function _initialize()
 {
     parent::_initialize();
     //實例化模型
     $this->d_ask = D('ask');
     $this->d_object = D('Object');
     $this->mid = is_login();
 }
開發者ID:smartymoon,項目名稱:e-anjia,代碼行數:8,代碼來源:IndexController.class.php

示例4: _initialize

 public function _initialize()
 {
     parent::_initialize();
     if (!is_login()) {
         $this->error('對不起,請先登陸');
     }
     $this->d_ask = D('Ask');
     $this->mid = is_login();
 }
開發者ID:smartymoon,項目名稱:fang1001,代碼行數:9,代碼來源:AskController.class.php

示例5: _initialize

 protected function _initialize()
 {
     parent::_initialize();
     $uid = isset($_GET['uid']) && ($_GET['uid'] = intval($_GET['uid'])) > 0 ? $_GET['uid'] : is_login();
     //調用API獲取基本信息
     $user_info = $this->userInfo($uid);
     $this->_fans_and_following($uid, $user_info);
     $this->_tab_menu();
 }
開發者ID:admpub,項目名稱:OpenCenter,代碼行數:9,代碼來源:IndexController.class.php

示例6: _initialize

 public function _initialize()
 {
     parent::_initialize();
     $session = session('wcInfo');
     $model = D();
     $this->myInfo = $model->Table(array('1008_user' => 'us'))->where('us.id = ' . $session['id'])->find();
     $myInfo = $this->myInfo;
     $this->assign('myInfo', $myInfo);
 }
開發者ID:tearys,項目名稱:lucky,代碼行數:9,代碼來源:IndexController.class.php

示例7: _initialize

 /**
  * 初始化
  */
 protected function _initialize()
 {
     parent::_initialize();
     // 檢查用戶登錄狀態
     $this->assign('currUser', $this->currUser);
     if (!$this->isLogined) {
         exit('<script>top.location.href="' . U('Public/login') . '";</script>');
     }
 }
開發者ID:dalinhuang,項目名稱:edu_hipi,代碼行數:12,代碼來源:BaseLoginController.class.php

示例8: _initialize

 public function _initialize()
 {
     parent::_initialize();
     //實例化模型
     if (!($mid = is_login())) {
         $this->error('對不起,請先登陸');
     }
     $this->mid = $mid;
     $this->d_object = D('object');
 }
開發者ID:smartymoon,項目名稱:fang1001,代碼行數:10,代碼來源:ObjectController.class.php

示例9: _initialize

 protected function _initialize()
 {
     parent::_initialize();
     if (!is_login()) {
         $this->error('請登陸後再訪問本頁麵。');
     }
     $this->setTitle('編輯資料');
     $this->_assignSelf();
     $this->_haveOtherRole();
 }
開發者ID:admpub,項目名稱:OpenCenter,代碼行數:10,代碼來源:ConfigController.class.php

示例10: _initialize

 protected function _initialize()
 {
     parent::_initialize();
     if (session('?uid') && is_login() > 0) {
         if (!defined("UID")) {
             define('UID', session('uid'));
         }
     } else {
         $this->error(L('ERR_SESSION_TIMEOUT'), U('Public/logout'), 3);
     }
 }
開發者ID:h136799711,項目名稱:201507banma,代碼行數:11,代碼來源:CheckLoginController.class.php

示例11: _initialize

 public function _initialize()
 {
     parent::_initialize();
     $user_info = $this->user_info;
     $identity = $user_info['identity'];
     if (!is_login() || $identity == 0) {
         $this->success('僅認證會員可操作');
     }
     $this->d_ask = D('Ask');
     $this->mid = is_login();
 }
開發者ID:smartymoon,項目名稱:e-anjia,代碼行數:11,代碼來源:AskController.class.php

示例12: _initialize

 public function _initialize()
 {
     parent::_initialize();
     //實例化模型
     $this->d_property = D('Property');
     $this->d_object = D('Object');
     $this->mid = is_login();
     //控製權限
     if (!check_auth('Property')) {
         // $this->error('對不起,隻有認證的機構用戶可以訪問該頁麵');
     }
 }
開發者ID:smartymoon,項目名稱:e-anjia,代碼行數:12,代碼來源:PropertyController.class.php

示例13: _initialize

 public function _initialize()
 {
     parent::_initialize();
     //實例化模型
     $user_info = $this->user_info;
     $identity = $user_info['identity'];
     if (!($mid = is_login()) || $identity == 0) {
         $this->success('僅認證會員可操作');
     }
     $this->mid = $mid;
     $this->d_object = D('object');
 }
開發者ID:smartymoon,項目名稱:e-anjia,代碼行數:12,代碼來源:ObjectController.class.php

示例14: _initialize

 /**
  * [_initialize 公共數據調用]
  * @return [type] [description]
  */
 public function _initialize()
 {
     parent::_initialize();
     //欄目列表
     $columnList = $this->getColumn();
     $this->columnList = $columnList;
     //麵包屑導航
     $colId = I('colId', '1', 'int');
     $columnParent = $this->getColumnParent($colId);
     $this->columnParent = $columnParent;
     $this->columnParentLength = count($columnParent);
     $this->nowcol = $columnParent[0]['id'];
     //獲取欄目詳情
     $columnInfo = $this->getColumnInfo($colId);
     $this->columnInfo = $columnInfo;
 }
開發者ID:hardphp,項目名稱:hard,代碼行數:20,代碼來源:IndexController.class.php

示例15: _initialize

 protected function _initialize()
 {
     parent::_initialize();
 }
開發者ID:admpub,項目名稱:OpenCenter,代碼行數:4,代碼來源:SystemController.class.php


注:本文中的BaseController::_initialize方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。