struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dave Newton <newton.d...@yahoo.com>
Subject Re: Error messages
Date Wed, 10 Sep 2008 12:01:41 GMT
--- On Wed, 9/10/08, Cosmin Marginean wrote:
> Sorry for the misunderstanding - might not have been so
> clear. I meant performing some logic in the JSP. I would 
> like to be able to do something like:
> <td
>     <c:if test="${<an error for field 'xxx' exists>}">
>         class="someErrorClass"
>     </c:if>

...

In that case, use ValidationAware's getFieldErrors().

<s:if test="getFieldErrors('xxx') != null">
  class="someErrorCalss"
</s:if>

(Syntax may be off.)

Dave

> > --- On Wed, 9/10/08, Cosmin Marginean wrote:
>>> Is there a way to check if a certain field errorhas been set?
>> In S2 use ValidationAware's getFieldErrors(...) method.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message