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=21613>. 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=21613 nested:error tag stopped displaying error messages (of certain scenario) when upgraded from Struts1.1 R1 to Final version ------- Additional Comments From [EMAIL PROTECTED] 2003-08-14 21:34 ------- I ran into this same problem, and have a work-around that may be useful. I added two calls to setName() in NestedErrorsTag.doStartTag(). import org.apache.struts.Globals; import org.apache.struts.taglib.html.ErrorsTag; import org.apache.struts.taglib.nested.NestedNameSupport; import org.apache.struts.taglib.nested.NestedPropertyHelper; /** * NestedErrorsTag. * @author Arron Bates * @author David Winterfeldt * @since Struts 1.1 * @version $Revision: 1.5 $ $Date: 2003/02/28 05:15:06 $ */ public class NestedErrorsTag extends ErrorsTag implements NestedNameSupport { /** * Overriding method of the heart of the matter. Gets the relative property * and leaves the rest up to the original tag implementation. Sweet. * @return int JSP continuation directive. * This is in the hands of the super class. */ public int doStartTag() throws JspException { // get the original properties originalName = getName(); originalProperty = getProperty(); // NestedPropertyHelper.setNestedProperties() will only adjust the property // attribute to its nested value if the 'name' attribute either is null or // Constants.BEAN_KEY. The causes a problem because the default value for // 'name' in ErrorsTag is Globals.ERROR_KEY. Setting 'name' to // Constants.BEAN_KEY... setName(Constants.BEAN_KEY); // request HttpServletRequest request = (HttpServletRequest)pageContext.getRequest(); // set the properties NestedPropertyHelper.setNestedProperties(request, this); // Also, setNestedProperties() will set the 'name' attribute to the // form bean, which will cause an exception below in super.doStartTag() // when it tries to retrieve the action messages. Resetting 'name' to its // original value... setName(Globals.ERROR_KEY); // let the super do it's thing return super.doStartTag(); } ... the rest of the class in unchanged. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]