Looking at the source for the ErrorsTag, it definitely is designed only to output error messages.

It seems you could pretty easily subclass ErrorsTag with a tag that uses the presence or absence of an error message for the given property to decide whether to return Tag.SKIP_BODY or Tag.EVAL_BODY_INCLUDE from doStartTag. Then your warning image HTML could be nested inside your <jamesBrown:errorsPresent> tag.

You'll have to decide whether this feature is worth that effort, but there it is.

-john.


Brown, James wrote:


The desire is:
 1. All errors will appear in one place - the top of the page.
 2. Any field for which validation errors have been detected, would be further flagged 
in 1 of three potential ways:
    a. changing the fields background colour;
    b. marking it with an exclamation icon (thanks to eBay for the quick sample); or
    c. including the error message (in this case "Last Name is invalid.") in the title 
attribute of the input.

#1 is easily achieved; however, I have been struggling with #2 in any form. The html:errors tag makes it very easy to output the message for a specific field, but I cannot seem to find a means to use it to "flag" that an error has occurred.



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to