views:

28

answers:

1

I am running weblogic 9. When I enter an incorrect URL below the application root I redirect 404 request to a customized error page.

Eg. http://localhost:7001/myApp/non-existent redirects to my customised error page.

Is there a way to do this for all incorrect URLs entered, not necessarily below the application root?

Eg. http://localhost:7001/anything_non-existent should redirect to my customized error page, not the web-logic default one?

Thanks

+1  A: 

The application's web.xml is where you define the error-page for <error-code>404</error-code>

http://localhost:7001/anything_non-existent is actually looking for a missing web application.

If you have a web server like Apache in front of Weblogic, that is the right place to trap this and redirect to 404.

JoseK