struts2.0之struts.xml详解 (续一)

来源:互联网 发布:淘宝店仓库管理 编辑:程序博客网 时间:2024/06/14 00:04
 

struts2 配置文件struts.xml method={1} {1} {n} method="{num}"

  1. <action  
  2.     name="/edit*"  
  3.     class="com.Del{1}Action">  
  4.     <result  
  5.         name="failure"  
  6.         path="/requ.jsp"/>  
  7.     <result  
  8.         path="/{1}.jsp"/>  
  9. </action>

     {n}指一个action内第n个星号所代表的内容,

struts2  struts.xml   method="{1}" | struts.xml  method="{1}" |struts.xml  {1}| struts.xml  {n}

 

例:

<s:form action="login_checkUser_zdz" method="post">

 

 <action name="login_*_*" class="com.jeecn.action.LoginAction"  method="{2}{1}">
               <result name="success">/success.jsp</result>
               <result name="input">/login.jsp</result>
       </action>

 

Action method: -----------zdzcheckUser

原创粉丝点击