继承类:
class MY_Auth_db extends CI_DB {
public function __construct($config = array())
{
parent::__construct($config);
$this->CI =& get_instance();
}
public function column()
{
$result = parent::get();
return $result;
}
}
调用:
$this->CI->load->library('MY_Auth_db');
$result = $this->CI->my_auth_db->select('*')->from('auth_access')
->column();
报错:
Type: Error Message: Call to undefined method MY_Auth_db::_execute() Filename: D:\qampp\htdocs\base\system\database\DB_driver.php
不太明白父类的get()为什么会调子类的方法?
|