Yii默认控制器并尝试首先找到匹配的控制器路由?

Say I have 3 Controllers ShareController, IndexController and AjaxController

I set the IndexController as the DefaultController. But I would like /share to show the Index Action of Share instead of trying to find the share Action of IndexController

My current urlManager:

'rules'=>array(
          '<action:\w+>' => 'site/<action>',
          '<controller:\w+>/<id:\d+>'=>'<controller>/view',
          '<controller:\w+>/<action:\w+>/<id:\d+>'=>'<controller>/<action>',
          '<controller:\w+>/<action:\w+>'=>'<controller>/<action>'

Add this rule inside your url-manager rules:

"share" => "share/index"