- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-12-2018 01:04 PM
Everything I'm finding says that <g2:no_escape> should work to display a kb article's text field (a translated HTML field) in its formatted form (so This is bold instead of <b>This is bold</b>), but it's not working for me. This is the snippet of the jelly:
<div style="padding-left:40px">
<b><h3><div style="color:#6f6f6f">$[kbArt.u_outline_order] $[kbArt.short_description]</div></h3></b>
<div style="padding-left:10px"><g2:no_escape>$[kbArt.text]</g2:no_escape></div>
</div>
This is however, resulting in the html code being displayed instead. Where am I going wrong?
Solved! Go to Solution.
- 3,272 Views
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-14-2018 06:38 AM
I was able to resolve the issue by changing all j2 and g2 tags to j and g. I'm not positive why this worked, but it did and that's all I care about.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-14-2018 06:38 AM
I was able to resolve the issue by changing all j2 and g2 tags to j and g. I'm not positive why this worked, but it did and that's all I care about.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-14-2018 07:08 AM
When I was looking for a reason why the no_escape did not work for you, I stumbled on this article: https://community.servicenow.com/community?id=community_blog&sys_id=b62da6e5dbd0dbc01dcaf3231f9619a8...
If you check the first comment by Göran followed by the comment of stephenn, stephenn presents an issue with phase 1 no_escape, concretly your page will fail if the text contains &. Just try adding "&" in your HTML field and see what happens, normally it causes the page to fail.