struts2 中action之间的传值

1.struts.xml中

<action name="qy_*" method="{1}" class="qYAction" >
			<result name="teacherLogin" type="redirect">gm_teacherLogin.do?username=${loginName}&amp;password=${password}</result>
			<result name="studentLogin" type="redirect">yh_studentLogin.do?username=${username}&amp;password=${password}</result>
</action>


2.传出页面
要有loginName,password的get,set方法,type类型为redirect.


你可能感兴趣的:(struts2,action之间传值)