Hi , I am sending the sample example then get solution. Please try follows a snippet of code in the struts.xml file: <action name="add" class="org.paradigmpop.mypopproject.pop.actions.AddAction"> <result name="input">/p/w/add_pop.jsp</result> <result name=" error " type="redirect-action"> <param name="actionName">xyz.action</param> <param name="namespace">/namespace</param> </result> <result name="success">/add_pop.jsp</result>
</action> Thank you, Seshagiri V seshagi...@kensium.com. US Main: 877 KENSIUM (536.7486) US Fax: 312.242.3029 Kensium 200 S Wacker Dr, Suite 3100 Chicago, IL 60606 Confidentiality Note: ----------------------------- The information contained in this e-mail is strictly confidential and for the intended use of the addressee only. Any disclosure, use or copying of the information by anyone other than the intended recipient is prohibited. If you have received this message in error, please notify the sender immediately by return e-mail and securely discard this message. -----Original Message----- From: ManiKanta G [mailto:go4m...@gmail.com] Sent: Wednesday, January 28, 2009 12:35 PM To: Struts Users Mailing List Subject: Re: how to redirect error page to struts action > > to which filter mapping? FilterDispatcher's mapping? > And could give sample snippet of web.xml using .action for http 404 error? > Well I got it... yes, for FilterDispatcher's mapping only the dispatcher config should be there. Reason: .... If no types are specified, the default option is REQUEST. (from http://docs.sun.com/app/docs/doc/819-3669/6n5sg7b0b). Thanks Dave. So by default filters will intercept only for REQUEST type. If we want to use action result as the error page, then the FilterDispacther need to intercept that request which is of error type. That's why we need to explicitly tell that. With '404' configured some where in the struts action config, below snippet is useful for using action result as error page: <filter-mapping> <filter-name>struts2</filter-name> <url-pattern>/*</url-pattern> <dispatcher>ERROR</dispatcher> </filter-mapping> <error-page> <error-code>404</error-code> <location>/404.action</location> </error-page> ManiKanta Internal Virus Database is out of date. Checked by AVG - http://www.avg.com Version: 8.0.176 / Virus Database: 270.10.0/1862 - Release Date: 12/23/2008 12:08 PM --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org