No jsp error!
Ok, here''s the deal. I got this half done(by someone else) web application andthere's a problem I can't solve. It uses Hibernate, Struts and Tomcat.
Whenever a .jsp page is built and it's got erros in it, it simply doesn't show up! I just get a blank screen in the broswer and no message on the tomcat console.
For example, say I have a java bean named "thing" and I accidently mispell it in the .jsp file as "thingg", so usually that would give me(at least in another project I worked on) some kind of error message on the tomcat console saying that bean doesn't exist etc...
Now with this application it doesn't do anything! It does render the other jsp frames, except the one with error. And if the code is correct then the jsp is rendered ok! So how do I make it display errors? Sorry if I posted in the wrong forum, as I'm not sure this is jsp related. Thanks in advance!
[914 byte] By [
muriloa] at [2007-10-2 6:23:42]

Have a look for try / catch blocks in the code. In the catch block ad a line to print the error to screen:
catch (Exception e)
{
// add the following line
out.println(e);
}
There may also be an error page defined in the xml config file which could have been left blank. Have a look in the config and see if one is defined, in Tomcat this would be in in web.xml
Sorry, if it uses struts I am pretty sure this has its own way of handling errors, it is more than likely this struts feature that is being used, cant help with this Im afraid, I decided not to use struts
thanks for the info, angrycat. I tried putting a "System.out.println(e);" line inside the catch block (the one from xxxxAction.java in the execute method, right?) but nothing happens :( Isn't my kind of error generated after the process leaves that class when bulding the .jsp compiled fille?
About the error page, there's a mapping which leads to no where, but since I also put a out.println("test") line before the ' return "error" ' statement I know the code is definitly not going inside the catch block! Any other clues?
Allright!!!! Thanks, evnafets! I looked in Tomcat logs and the errors are going there! That hepls! thanks!!!!
but I'd still like to know if it's possible to make Tomcat display errors in its console insead. y'know, kind of annoying having to open the log everytime hehehe
Yes, I'm using strtus tiles, and another project which used tiles as well, would show .jsp errors in its console. So how do I configure that?