Hi,
I have annotated my exception class with the @HttpError to return the 404 error
code:
@ApplicationException(rollback=true)
| @HttpError(errorCode=HttpServletResponse.SC_NOT_FOUND)
| public class NAPEntityNotFoundException extends Exception implements
Serializable {
|
When I throw the exception I get redirected to the standard tomcat 404 error
page. Good.
However, ideally I would like to display my own error page. When I configure
this in my web.xml:
<error-page>
| <error-code>404</error-code>
| <location>/public/error/errorPage.xhtml</location>
| </error-page>
something weird happens.
I do not get redirected to any error page, but instead my browser pops up a
dialog with the following message:
anonymous wrote : The file "viewContent.jsf" is of type application/xhtml, and
Mozilla does not know how to handle this file type. This file is located at:
http://localhost:8080 What should Mozilla do with this file? Open it, Save it
Note that the page "viewContent.jsf" above is the page which was being
displayed at the time when I threw the exception. Any suggestions as to what I
can do ?
Thanks
Louis
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979295#3979295
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979295
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user