zindi
Apr 17th, 2011, 11:50 PM
Hi all,
I am trying to inject HTML to the view using jstl but it is not being rendered as HTML but as plain text. Here is a sample of what I am using
<c:set var="msg" value="hi <b>Test</b>!" />
<c:out value='${msg}' escapeXml="true" /> <br><br>
<c:out value='${msg}' escapeXml="false" /> <br><br>
${msg}
and my output in the view is
hi <b>Test</b>!
hi <b>Test</b>!
hi <b>Test</b>!
What I would like to do is display the word "Test" in bold. I am using Spring 3.
Thanks in advance.
I am trying to inject HTML to the view using jstl but it is not being rendered as HTML but as plain text. Here is a sample of what I am using
<c:set var="msg" value="hi <b>Test</b>!" />
<c:out value='${msg}' escapeXml="true" /> <br><br>
<c:out value='${msg}' escapeXml="false" /> <br><br>
${msg}
and my output in the view is
hi <b>Test</b>!
hi <b>Test</b>!
hi <b>Test</b>!
What I would like to do is display the word "Test" in bold. I am using Spring 3.
Thanks in advance.