You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by bu...@apache.org on 2003/07/07 09:22:57 UTC
DO NOT REPLY [Bug 21359] New: -
Struts Error Handling Framework Problem
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21359>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21359
Struts Error Handling Framework Problem
Summary: Struts Error Handling Framework Problem
Product: Struts
Version: 1.1 Final
Platform: All
OS/Version: All
Status: NEW
Severity: Normal
Priority: Other
Component: Controller
AssignedTo: struts-dev@jakarta.apache.org
ReportedBy: rodneyp@natdata.net
I am currently experiencing a problem with the Struts error handling framework.
I am trying to use the error handling framework from ActionForm and
LookupDispatchAction classes.
The problem I have is in regards to display of error messages. I have found
that error messages are being displayed correctly using the <html:errors/> tag
from a ActionForm validate method, but are not being displayed using the
LookupDispatchAction methods. Please see below:
ActionForm
public ActionErrors validate(ActionMapping actionMapping, HttpServletRequest
httpServletRequest) {
ActionErrors errors = new ActionErrors();
errors.add("field", new ActionError("messageKey"));
return errors;
}
LookupDispatchAction
public ActionForward next(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response) {
...
ActionErrors errors = new ActionErrors();
errors.add("field", new ActionError("messageKey"));
if(!errors.isEmpty()) {
saveErrors(request, errors);
}
return (ActionForward)mapping.findForward(target);
}
Could someone please tell me why this is so. I would be most interested if
anyone could provide a solution for this.
NOTE:
I am using the Struts version 1.1 release with tomcat version 4.1.24
Yours Sincerely
Rodney Paul
ps. You can contact me via email at rodney.paul@natdata.net
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-dev-help@jakarta.apache.org