struts 2--actionwildcard 通配符配置

1.当调用方法为x时{1}即为x

<package name="actions" extends="struts-default" namespace="/actions">

<action name="Student*" class="" method="{1}">

<result>/Student{1}_success</result>

<action>

<action name="*_*" class="com.bjsxt.struts2.action.{1}Action" method="{2}">

<result>

/{1}_{2}_success.jsp>

</result>

</action>

</package>

posted @ 2011-12-26 15:22  汉卿  Views(255)  Comments(0Edit  收藏  举报