Skip to Content

Use of Error Pages

Hallo Suresh,

> Could you please tell me why there is an error page

> in the BSP page/controller attribute

The error page in MVC was plan long time ago so that when an error happened somewhere in a controller/view, then the error page will be triggered to handle the rendering (for example message of error and info on how to call for help). Also, once the error page is processed, the rest of the controller tree is processed.

However, the MVC design/implementation was done in parallel to that of the BSP extensions and the HTMLB library. The problem is that the HTMLB library has an expected hierarchy that must be in place. Once an error happens, you have no idea of what the current state of the hierarchy is, and how was rendered. And now suddenly, if you try to again use the htmlb content tag in the error page, you get a new exception that the content tag is already on the stack. These two designs clashed here.

My very personal feeling: do not use error pages. They are not helping you. For real error handling of the termination kind, just raise exception. This is caught in the kernel and outputed into browser. If you then want a specific formatted page (mobile number of manager:), use the features of ICF for this node to configure custom error pages.

For other error messages to display, gather them and display them any way you like. If you are using textView, consider to look into PHTMLB library. There is a messageBar tag (but it can only display one message unfortunately) or my favourite, the formatted text.


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Jun 19, 2004 at 12:42 AM


    Thanks for your clarification. Yes, I used PHTMLB and also cute Icons to display Warning and Error messages in the event of an error. I used iteration to display multiple error messages in the view.



    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.