On Wed, Feb 19, 2003 at 05:59:34PM +0100, Rickard Öberg wrote: > Anders Engström wrote: > >That sounds resonable, when you put it that way. Am I correct in my > >assumption that you can return your own 'result' from an action - it > >doesn't have to be 'error', 'success' etc. to map the result > >string to a view? > > Yes, we just predefined a couple that seemed common. But you can return > anything, as long as you match 'em with corresponding view mappings. >
Re-thinking this exception thing... I agree that WW should not select views based on exception class - but (from a web-front-end view) there should be a way for an application to present its own error page (with nice layout and perhaps an "email sysadmin button" on it :). In the current code-base when an exception is thrown in action.execute() a standard web-work page is rendered by ServletDispatcher. There is no (?) way to override this. It would be very useful if one could define an application error page in views.properties on-exception.view=error.jsp or an action-specific exception view HelloAction.on-exception.view=hello_error.jsp this view would receive the exception the normal way (provided the jsp "isErrorPage"). //Anders -- |===================================| | Anders Engström | | [EMAIL PROTECTED] | | http://www.gnejs.net | |===================================| |Your mind is like an umbrella. | |It doesn't work unless you open it.| | /Frank Zappa | |===================================|
msg01886/pgp00000.pgp
Description: PGP signature