Andy on 20/01/09 17:49, wrote:
Using the Exception interceptor works great for catching exceptions throw by
actions.  However I am wondering what is the recommended method for catching
and handling exceptions thrown by a JSP?  I assume that JSP exceptions are
outside the S2 scope and are to be handled at the container level?

Assumption correct.

Your situation might be quite simple if you have a basic JSP. Put in an error declaration

<%@ page errorPage="/WEB-INF/jsp/error.jsp" %>

and handle it there.

If you're using multiple JSPs with a templating system like tiles, it gets more complicated. I do and I put a meta-redirect in my error JSP so that the browser doesn't show the mix of correct and broken fragments.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to