Yii通过页面url发送索引操作的参数

mysite/users triggers usersController index action.

Now I want to send mysite/users/123 to usersController.

How Can I do it ? and where to will go this request if not to index action ?

Updated form comments discussion

If you want to pass 123 to the controller you need to set the named parameter in the urlManager of the config/main.php file.

'something/<namedParameter:Pattern>' => 'MyControllerToCall/MyMethodofControllerToUse'

So for you:

'users/<username:\d+>' => 'users/view'

In the view

public function actionView($username){

echo $username;
}

That will only work in the view method though as the 123 part is being taken from the URL and you have configured Yii so when the url mysite/users/ is displayed like mysite/users/123. It calls the View method of the users Controller.