Ejemplo n.º 1
0
 public function __construct()
 {
     parent::__construct();
     header('Cache-control: private, must-revalidate');
     if (!$this->checkAccess()) {
         $this->error("没有操作权限");
     }
 }
Ejemplo n.º 2
0
 protected function display($tplFile = null, $cacheTime = null, $cachePath = null, $stat = false, $contentType = "text/html", $charset = "", $show = true)
 {
     //验证模板文件
     //		if (is_file($tplFile) && is_readable($tplFile)) {
     $cacheDir = $this->cacheDir;
     parent::display($tplFile, $cacheTime, $cacheDir);
     //		}
 }
Ejemplo n.º 3
0
 /**
  * 调用模板
  */
 protected function display($tplFile = null, $cacheTime = null, $cachePath = null, $stat = false, $contentType = "text/html", $charset = "", $show = true)
 {
     //验证模板文件
     if (is_file($tplFile) && is_readable($tplFile)) {
         //设置缓存目录
         $cachePath = $this->get_cache_path();
         parent::display($tplFile, $cacheTime, $cachePath);
     }
 }
Ejemplo n.º 4
0
 public function __construct()
 {
     parent::__construct();
     if (!$this->checkAccess()) {
         $this->error("没有操作权限");
     }
     //消息数
     $message_count = M("user_message")->where(array('to_uid' => $_SESSION['uid'], 'user_message_state' => 0))->count();
     $this->assign('message_count', $message_count);
     //信息信息
     $systemmessage_count = M("system_message")->where(array('uid' => $_SESSION['uid'], 'state' => 0))->count();
     $this->assign('systemmessage_count', $systemmessage_count);
 }
Ejemplo n.º 5
0
 public function __construct()
 {
     parent::__construct();
     //会员中心是否关闭
     if (C("member_open") == 0 && empty($_SESSION['admin'])) {
         $this->display("./data/Template/close_member");
         exit;
     } else {
         if (!session('uid')) {
             go(U("Member/Login/login"));
         } else {
             if (!empty($_SESSION['lock'])) {
                 //锁定用户无法操作(IP禁止,限制访问日期等)
                 $this->error('您已被锁定,无法进行操作', __WEB__);
             }
         }
     }
 }
Ejemplo n.º 6
0
 function __construct()
 {
     parent::__construct();
 }