HI,
I am try to do something simple in struts, but there's no updated
documentation on it.
I have declared a global exception thrown when I get this particular
exception:
<global-exceptions>
<exception
type="my.exception.SessionExpiredRtException"
key="error.fatal.session.expired"
path="/WEB-INF/jsp/error/fatal-error.jsp"
/>
</global-exceptions>
And I just want to redirect to a simple page at
/WEB-INF/jsp/error/fatal-error.jsp when this exception is thrown. And
in the property file, there is a error.fatal.session.expired key where
the text is put.
Ok. So how must I write the JSP page to get back the error message??
I have tried many possibilities, and I dont find it. Where does Struts
store the error key "message"??
I have tried that and it does'n work.
<logic:present name="<%=Globals.MESSAGE_KEY%>">
<P><html:errors property="<%=Globals.MESSAGE_KEY%>"/></P>
</logic:present>
What is the good JSP code?
Thanks
etienno@gmail.com - 27 Jul 2006 16:08 GMT
> HI,
>
[quoted text clipped - 31 lines]
>
> Thanks
Found it: <html:errors/>