开发者

JSF setting div class after validation exception

at the moment I've got a construct like this:

<div class="line">
   <label>Label</label>
   <h:inputText id="text-id1" required="true" ... />
</div>

Now when a validation exception is thrown I show them in a

<h:messages ... />

Is it possible to set the error clas开发者_JS百科s to my wrapping div?


<div class="#{facesContext.maximumSeverity == null ? 'line' : 'errorLine'}">


I know this isn't exactly what you asked, but i thought i should include it for completeness.

 <h:message errorClass="errorline" infoClass="line"/>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜