yii2.0框架修改默认控制器 配置config目录下的 main.php 代码:'defaultRoute' => 'site', 修改默认方法 代码:public $defaultAction = 'yiiindex';