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=13565>. 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=13565 To "errors", add prefix, suffix, header, footer attrs, to "messages", add prefix, suffix attrs Summary: To "errors", add prefix, suffix, header, footer attrs, to "messages", add prefix, suffix attrs Product: Struts Version: Nightly Build Platform: Other OS/Version: Other Status: NEW Severity: Enhancement Priority: Other Component: Custom Tags AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] It appears to me that the "html:messages" tag is somewhat handicapped, in comparison to the "html:errors" tag. The "html:errors" tag can use a "prefix" and "suffix" for each error. There appears to be nothing like this for the "html:messages" tag. There is a "header" and "footer" for both tags, which is printed before and after the LIST of errors or messages, but nothing to put around each message. It's also curious that the way the "header" and "footer" are defined in these tags is different. The "html:errors" tag has a hardcoded resource name to retrieve the header and footer (and prefix and suffix), but the "html:messages" tag has "header" and "footer" attributes to specify a key to use. I like using the attribute value to specify this, or at least override it. I propose the following changes: Change the "html:messages" tag, adding two new attributes, named "prefix" and "suffix", which specify the message keys for a prefix and suffix on each message. These are very similar to the existing "header" and "footer" attributes, but I also propose the following changes to how those two attributes are used, in addition to the two new ones: If the attribute is unset, it will use a default of "messages.header", etcetera. Note there is one subtle backwards compatibility issue with this change: If a user had an existing property named "messages.header", "messages.footer", "messages.prefix", or "messages.suffix", and they had a "html:messages" element without any of the attributes "header", "footer", "prefix" or "suffix", then the behavior of their "html:messages" tag would change, in a likely unintended way: it would now use the value of "messages.header" (and others). On the "html:errors" tag, I would make it work consistently, adding four new attributes, of the obvious names, which will use defaults if unset, being the existing values of "errors.header", etcetera. The change to this tag has no backwards compatibility issue, because if the attributes were unset, it was always defined to use the existing "errors.header" resources. Adding this functionality to the "html:errors" tag would give developers the ability to have more than one pattern for displaying errors in their application. Presently, they can only define the "errors.header" resources once, so all displays of "html:errors" will use the same patterns. -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>