命名空间是到文件夹的:namespace PHPExcel\user;
使用是加上类名的,就是命名空间+类名字;
斜线都是使用\
最后面都不带斜线\
namespace app\controllers;
use app\common\components\BaseWebController;
PHP的namespace与use
最新推荐文章于 2022-10-24 14:35:13 发布
命名空间是到文件夹的:namespace PHPExcel\user;
使用是加上类名的,就是命名空间+类名字;
斜线都是使用\
最后面都不带斜线\
namespace app\controllers;
use app\common\components\BaseWebController;