You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@struts.apache.org by jh...@apache.org on 2007/08/01 18:22:19 UTC
svn commit: r561856 - in
/struts/struts2/trunk/core/src/main/resources/template/simple:
actionerror.ftl actionmessage.ftl fielderror.ftl
Author: jholmes
Date: Wed Aug 1 09:22:11 2007
New Revision: 561856
URL: http://svn.apache.org/viewvc?view=rev&rev=561856
Log:
WW-2080 actionError, actionMessage and fieldError Freemarker templates do not honor the cssClass and cssStyle attributes
Modified:
struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl
struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl
struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl
Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl
URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl?view=diff&rev=561856&r1=561855&r2=561856
==============================================================================
--- struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl (original)
+++ struts/struts2/trunk/core/src/main/resources/template/simple/actionerror.ftl Wed Aug 1 09:22:11 2007
@@ -23,7 +23,16 @@
<#if (actionErrors?exists && actionErrors?size > 0)>
<ul>
<#list actionErrors as error>
- <li><span class="errorMessage">${error}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="errorMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${error}</span></li>
</#list>
</ul>
</#if>
Modified: struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl
URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl?view=diff&rev=561856&r1=561855&r2=561856
==============================================================================
--- struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl (original)
+++ struts/struts2/trunk/core/src/main/resources/template/simple/actionmessage.ftl Wed Aug 1 09:22:11 2007
@@ -23,7 +23,16 @@
<#if (actionMessages?exists && actionMessages?size > 0)>
<ul>
<#list actionMessages as message>
- <li><span class="actionMessage">${message}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="actionMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${message}</span></li>
</#list>
</ul>
</#if>
Modified: struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl
URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl?view=diff&rev=561856&r1=561855&r2=561856
==============================================================================
--- struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl (original)
+++ struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl Wed Aug 1 09:22:11 2007
@@ -37,7 +37,16 @@
<#assign doneStartUlTag=true><#t/>
</#if><#t/>
<#list eValue as eEachValue><#t/>
- <li><span class="errorMessage">${eEachValue}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="errorMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${eEachValue}</span></li>
</#list><#t/>
</#if><#t/>
</#list><#t/>
@@ -52,7 +61,16 @@
<#list eKeys as eKey><#t/>
<#assign eValue = fieldErrors[eKey]><#t/>
<#list eValue as eEachValue><#t/>
- <li><span class="errorMessage">${eEachValue}</span></li>
+ <li><span<#rt/>
+<#if parameters.cssClass?exists>
+ class="${parameters.cssClass?html}"<#rt/>
+<#else>
+ class="errorMessage"<#rt/>
+</#if>
+<#if parameters.cssStyle?exists>
+ style="${parameters.cssStyle?html}"<#rt/>
+</#if>
+>${eEachValue}</span></li>
</#list><#t/>
</#list><#t/>
</ul>