代码对的。大小写也是对的,但是调用db出错了,是我配置出现了问题吗
[1] ErrorException in Test.php line 12
Class 'Util\data\Sysdb' not found
use think\Controller;use Util\data\Sysdb;/***
*/class Test extends Controller{ public function index(){ $this->db = new Sysdb; $res = $this->db->table('admins')->where(array('id'=>1))->item(); dump($res); }}
Call Stack
in Test.php line 12at Error::appShutdown()