-
1. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
jaysensharma Jun 24, 2012 1:52 AM (in response to adheep)1 of 1 people found this helpfulHi Adheep,
At the application level you can use the following kind of entry inside your "WEB-INF/web.xml" file to define your own Error Page
<error-page>
<error-code>404</error-code>
<location>/Error404.html</location>
</error-page>At the front end also you can configure Error Page for JBossAS7 as described in the following link:
http://middlewaremagic.com/jboss/?p=1334 (Custom error pages in Apache for JBoss AS7)
-
2. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
adheep Jun 25, 2012 5:51 AM (in response to jaysensharma)@Jay Kumar SenSharma: Thanks for the reply it really worked
-
3. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
greco Sep 10, 2012 11:24 AM (in response to adheep)Hi at the application level is fine with the changes in the web.xml, but what if you don't have a front end apache and use jboss to listen on port 80. If someone enters a bad context in the url they are still presented with the default jboss messages.
or
http://localhost:8080/idontexist
will still return a JBoss 404 error message. Where would one go about changing these?
-
4. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
nimo22 Feb 5, 2013 2:34 AM (in response to greco)I also want a application-wide replacement for 404-page.
I cannot find the jboss 404 page to replace it with my own.
I have also looked at directory "jboss-as-7.1.1.Final\welcome-content\..".
Maybe it is generated by code?
Can I use the application.xml to add my custom 404 page?
-
5. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
jaikiran Feb 5, 2013 2:49 AM (in response to nimo22)I also want a application-wide replacement for 404-page.
There's nothing JBoss specific to this. The EE spec allows each application to package its own custom error pages and configure them in web.xml. Here's the documentation http://docs.oracle.com/javaee/6/tutorial/doc/bnaeo.html#gkbkw
-
6. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
nimo22 Feb 5, 2013 2:54 AM (in response to nimo22)I found the solution:
http://stackoverflow.com/questions/13476028/how-to-customize-jboss-as7-404-page
However, it would be nice and faster to replace 404-page by a xml-setting in application.xml.
-
7. Re: Can I make my own custom ERROR pages like 404 error in JBoss AS 7.1.1 ?
sundarcse1216 Feb 19, 2017 11:58 PM (in response to nimo22)Hi nimo,
I read that article but i am not understand that, still i cant get any idea. Please can you help me?
I have two war,
1. first.war
2.second.war
if anybody access other than this name mean, I have to redirect error message page. I am using Jboss-as7 Please explain step by step.
Thanks,
Sundar S