Forums Register Login

Handling Exception Declaratively in WEB-INF Or JSP Errpr Page

+Pie Number of slices to send: Send
Hello Guys,
What is the difference between handling exception declaratively in the web.xml descriptor and including a jsp error page tag in the jsp? Which are prefered in what situation? Since the declartive approach could catch exception from both servlets and jsp, why is there a need for the jsp error page tag? Are they redundant? Can some one explain further please? Preferably with examples. Thanks
regards
Rastin
+Pie Number of slices to send: Send
The nice thing about the JSP declared error page is that you get the exception variable plus the request and session (I think) so you can have a report that is exactly matched to what you are trying to do in the JSP.
Bill
"To do good, you actually have to do something." -- Yvon Chouinard
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 751 times.
Similar Threads
Head First Servlets & JSP book - Reader Question
doubt in free mock exam
How to handle an Exception thrown in a Scriptlet in a .Tag File
New forum for Sun Certified Web Component Developer
Error Handling in Jsp
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 19, 2024 04:41:48.