|
PHP复制代码
class Video extends CI_controller {
/**
* 构造方法
*/
function __construct (){
parent ::__construct ();
$this->session->userdata['user_id']!='' ? : redirect ('login');
$this->load->model('video_model','video');
//$this->load->model('user_model','user');
}
/**
* 方法名:video_category
* 作用:查询分类名称
* */
private function video_category ($category_id){
$this->load->model('category_model','category');
$result = $this->category->videoByCid($category_id);
file_put_contents('result.txt', var_export($result,true));
}
复制代码
然后出现这个问题
HTML复制代码
A PHP Error was encounteredSeverity: Notice
Message: Undefined property: Video: category_model
Filename: controllers/video.php
复制代码
|
|