cancel
Showing results for 
Search instead for 
Did you mean: 

Use of Error Pages

former_member181879
Active Contributor
0 Kudos

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.

++bcm

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Brian,

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.

Thanks,

Suresh