/**
* 构造方法
*/
function __construct(){
parent::__construct();
$this->session->userdata['user_id']!='' ? : redirect('login');
$this->load->model('video_model','video');
$this->load->model('user_model','user',true);
}
private function _getUserById($uid){
$result = $this->user->userById($uid);
//file_put_contents('result.txt', var_export($result,true));
//exit();
}
A PHP Error was encountered
Severity: Notice
Message: Undefined property: Video::$user
Filename: controllers/video.php
Line Number: 47
function __construct(){
parent::Controller();
$this->load->model('m_socket','Socket');
$this->load->model('m_client','Client');
}
父类里有Controller 这个方法吗? 加载类时候的别名错了吧 是不是和控制同样的名称了
页:
1
[2]