struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@webotech.co.uk
Subject Re: ActionMessages not displayed in the UI
Date Wed, 12 Oct 2005 21:08:54 GMT
Thanks Dave that worked... my errors.jsp is pasted below. So I used two sets 
of tags one for the struts validation errors and one for the action errors. 
It would have been more elegant using only 1 set of tags but I guess this 
works just fine. 

<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ taglib uri="/tags/struts-logic" prefix="logic" %>
<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<html:xhtml/> 

<%-- This deals with the struts validation errors --%>
<logic:messagesPresent>
<html:messages id="err">
 <div class="ErrorMessage"><bean:write name="err" /><br /></div>
</html:messages>
</logic:messagesPresent> 

<%-- This deals with the action errors --%>
<logic:messagesPresent message="true" property="error">
<html:messages message="true" id="err" name="error">
 <div class="ErrorMessage"><bean:write name="err" /><br /></div>
</html:messages>
</logic:messagesPresent> 


Dave Newton writes:
...
> Does this help? 
> 
> Dave


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


Mime
View raw message