summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSidharth Singh2013-09-17 08:38:17 (EDT)
committer Stephan Born2013-09-17 08:38:17 (EDT)
commit4379232f54ab27a4ada15fec01411daad9248c60 (patch)
tree1d672033fd57c7f6ac32b5187713314bb9c812a0
parent0c7ead15cc8e751756f7474edb78fa37b854e985 (diff)
downloadorg.eclipse.stardust.ui.web-4379232f54ab27a4ada15fec01411daad9248c60.zip
org.eclipse.stardust.ui.web-4379232f54ab27a4ada15fec01411daad9248c60.tar.gz
org.eclipse.stardust.ui.web-4379232f54ab27a4ada15fec01411daad9248c60.tar.bz2
Jira-ID: CRNT-30243
Added StringEscapeUtils.escapeHtml(str) to encode JSF special chars present in str in java. Ex. "<" with &lt; git-svn-id: https://svn.csa.sungard.com/repos/ipp2/product/trunk/stardust/ui.web@67318 8100b5e0-4d52-466c-ae9c-bdeccbdeaf6b Signed-off-by: Sidharth Singh <sidharth.singh@sungard.com>
-rw-r--r--views-common/src/main/java/org/eclipse/stardust/ui/web/viewscommon/utils/I18nUtils.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/views-common/src/main/java/org/eclipse/stardust/ui/web/viewscommon/utils/I18nUtils.java b/views-common/src/main/java/org/eclipse/stardust/ui/web/viewscommon/utils/I18nUtils.java
index 473f4ef..238eb94 100644
--- a/views-common/src/main/java/org/eclipse/stardust/ui/web/viewscommon/utils/I18nUtils.java
+++ b/views-common/src/main/java/org/eclipse/stardust/ui/web/viewscommon/utils/I18nUtils.java
@@ -14,6 +14,7 @@ import java.text.MessageFormat;
import java.util.Collection;
import java.util.List;
+import org.apache.commons.lang.StringEscapeUtils;
import org.eclipse.stardust.common.CollectionUtils;
import org.eclipse.stardust.common.StringUtils;
import org.eclipse.stardust.common.log.LogManager;
@@ -366,7 +367,9 @@ public class I18nUtils
}
try
{
- label = Localizer.getString(key);
+ // Used StringEscapeUtils.escapeHtml to escape special characters in Java.
+ // Ex. <,> with &lt; &gt;
+ label = StringEscapeUtils.escapeHtml(Localizer.getString(key));
if (null == label && isComputedCaseDataPath(element))
{
label = findMatchingCaseDataPathLabel((DataPath) element, mode);