java - Struts : after loging need to redirect caller page -


i developing 1 application using strust2 , tiles. in that, there many pages user must have log in.

why need this, send page link query parameter user's input require. so, send jsp page request user on mail.

when user click on link first login page after success full login need redirect page sent on mail.

strust.xml

<!-- login -->         <action name="login" class="com.drms.controller.login">             <result name="success" type="redirect">summary.action</result>             <result name="error" type="tiles">maintiles</result>             <result name="input" type="tiles">forward_reqtiles</result>         </action> 

tils.xml

<definition name="main" template="main.jsp">         <put-attribute name="header" value="/header.jsp" />         <put-attribute name="content" value="/content.jsp" /> <!-- login page -->         <put-attribute name="footer" value="/footer.jsp" />     </definition> 

for redirecting, please use config:

<action name="login" class="com.drms.controller.login">         <result name="success" type="redirectaction">             <param name="actionname">summary</param>             <param name="namespace">/</param>           </result>         <result name="error" type="tiles">maintiles</result>         <result name="input" type="tiles">forward_reqtiles</result> </action> 

change own namespace


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -