On Jan 19, 2011, at 6:13 PM, mflorea (SVN) wrote:

> Author: mflorea
> Date: 2011-01-19 18:13:30 +0100 (Wed, 19 Jan 2011)
> New Revision: 34008
> 
> Modified:
>   
> platform/xwiki-applications/trunk/watchlist/src/main/resources/XWiki/WatchListMessage.xml
> Log:
> XPWATCHLIST-122: The HTML part of the watchlist notification mail is not 
> rendered under velocity 1.7
> * Escape quotes using an extra variable instead of "" in order to be 
> backwards compatible.
> 
> 
> Modified: 
> platform/xwiki-applications/trunk/watchlist/src/main/resources/XWiki/WatchListMessage.xml
> ===================================================================
> --- 
> platform/xwiki-applications/trunk/watchlist/src/main/resources/XWiki/WatchListMessage.xml
>  2011-01-19 17:02:04 UTC (rev 34007)
> +++ 
> platform/xwiki-applications/trunk/watchlist/src/main/resources/XWiki/WatchListMessage.xml
>  2011-01-19 17:13:30 UTC (rev 34008)
> @@ -292,11 +292,12 @@
>   #set($result = $result.replaceAll("${prefix}propDiffNewValue", 
> "$propDiffStyle background:#EDFFED;"))
>   #set($result = $result.replaceAll("${prefix}propDiff", "$propDiffStyle"))
>   #set($suffix = "_WATCHLIST_IMG_PLACEHOLDER")
> +  #set($q = '"')

If I was a PITA I'd say this should be explained since the next person who sees 
this will think Marius did a bad job and could have used "" instead (native 
synax) ;)

-Vincent

>   #foreach($totransform in ["attach", "object", "class", "metadata"])
> -    #set($result = $result.replaceAll("${totransform}${suffix}", "<img 
> src=""cid:${totransform}.gif"" style=""${iconStyle}"" 
> ${iconAttrs}></img>"))
> +    #set($result = $result.replaceAll("${totransform}${suffix}", "<img 
> src=${q}cid:${totransform}.gif${q} style=${q}${iconStyle}${q} 
> ${iconAttrs}></img>"))
>   #end
>   #foreach($totransform in ["boolean", "date", "dblist", "dbtreelist", 
> "groups", "levels", "number", "password", "staticlist", "string", "textarea", 
> "users"])
> -    #set($result = $result.replaceAll("${totransform}${suffix}", "<img 
> src=""cid:${totransform}.png"" style=""${iconStyle}"" 
> ${iconAttrs}></img>"))
> +    #set($result = $result.replaceAll("${totransform}${suffix}", "<img 
> src=${q}cid:${totransform}.png${q} style=${q}${iconStyle}${q} 
> ${iconAttrs}></img>"))
>   #end
>   $result
> #end

_______________________________________________
devs mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/devs

Reply via email to