Hi everyone:
why don't i modify namespace "app\controllers" to "abc\controllers", and i setted alias(Yii::setAlias('@abc', dirname(__DIR__)); ) in web/index.php.
run some mistake appeared as follow:
Unable to find 'app\controllers\DefaultController' in file: /xxx/abc/controllers/DefaultController.php. Namespace missing?
./controllers/DefaultControllers:
<?php
namespace app\controllers;
class DefaultController extends \Yii\web\Controller{}
but i modified:
./controllers/DefaultControllers:
<?php
namespace abc\controllers;
class DefaultController extends \Yii\web\Controller{};
and in web/index.php:
Yii::setAlias("@abc", dirname(__DIR__));
some mistake appeared:
Unable to find 'app\controllers\DefaultController' in file: /xxx/abc/controllers/DefaultController.php. Namespace missing?
what's wrong?Thanks.