怎么用ForwardAction把请求中的数据一起发到页面去,比如说:<html:form  action="fwdaction.do" styleId="form1">
姓名:<html:text property="name" styleId="name" />
<密码:<html:text property="pwd" styleId="pwd"/>
<html:submit value="提交"/><action path="/fwdaction" parameter="/MyJsp.jsp" attribute="userForm"
type="org.apache.struts.actions.ForwardAction" scope="request" name="userForm"
validate="false"></action>怎么才可以在MyJsp.jsp页面得到表单的数据呢 还有就是那个attribute属性是用来设置什么的呢

解决方案 »

  1.   

    但是没有啊 那个attribute是用来设置什么的啊
      

  2.   

    userForm  指的这个表单的名称:
    <html:form action="fwdaction.do" styleId="form1">
    姓名:<html:text property="name" styleId="name" />
    <密码:<html:text property="pwd" styleId="pwd"/>
    <html:submit value="提交"/>你采用struts的 js验证机制 然后看源码就知道了!
      

  3.   

    我知道了 原来在userForm 里面没有运行set方法 为什么呢 用其他的action他就会运行 就是提交到forwardaction的时候只运行了验证方法和reset方法 没有运行set方法