Search code examples
strutsrequest

Struts 1.3 ActionErrors access


In my ActionForm i have the validate method:

public ActionErrors validate(ActionMapping mapping, HttpServletRequest request){

    ActionErrors errorList = new ActionErrors();
    errorList.add("myError", new ActionMessage("this is my error"));
    return errorList;
}

Then the flow will be returned to the page form.jsp.

I want to access that error from my form.jsp page but using JSTL's EL and not html:error tag. I know that errorList is stored as an Attribute on the requests scope but I need the exact name of the attribute. Can you tell under what name is that errorList stored on the request? Thank you!


Solution

  • ERROR_KEY in Globals; its value is "org.apache.struts.action.ERROR".