thinkphp5中不需要继承基类就可以工作,但是建议间接继承控制器基类Controller
我们用Base.php继承控制器基类,这样在用户自定义的控制器就不用继承Controller了,直接继承Base即可
好出:用Base作为中间层可以定义一些公共方法和系统常量
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!