- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-10-2020 08:32 AM
Hello,
A piece of XML in a UI Macro that hasn't changed since 2014 is now causing HTML tags to display on the user end. The UI macro involves some old Jelly functionality and specifically a glide.ui.escape_text. Attached is the UI Macro causing the issue and the HTML tags in the request item. Please let me know if more information is needed to get to the bottom of this.
Solved! Go to Solution.
- Labels:
-
Service Level Management

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2020 10:20 AM
I actually wrote some code of my own today that required me to take data from a HTML type field on a table and display it on a UI Page so hopefully this works for you as well!
Although you are using escape HTML in the code try using it when you actually output it - see the code below.
<div>
<g:no_escape>${jvar_this_test_plan}</g:no_escape>
</div>
Thanks,
Dan

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-11-2020 03:38 PM
Hey,
If either of these properties exist, have they changed recently?
- glide.ui.escape_text
- glide.ui.escape_all_script
One thing to possibly try is replacing all your new line replacements to just be:
// use a BR tag for new lines
text = text.replace(/\n/g, "<br/>");
Let me know if any of this helped or not.
Thanks, Dan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2020 09:08 AM
Hey Dan,
Thanks for your help, Replacing all "INSERTNEWLINE" text replacements with "<br/>" seemed to work in some places but in approvals with more references to our UI Macros it just replaced the tags we were seeing before with the new text replacement. If there are any other potential workarounds you know of or if I implemented this the wrong way please let me know. Attached are screenshots of another request with the XML code and how I implemented it in our UI macros.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2020 10:20 AM
I actually wrote some code of my own today that required me to take data from a HTML type field on a table and display it on a UI Page so hopefully this works for you as well!
Although you are using escape HTML in the code try using it when you actually output it - see the code below.
<div>
<g:no_escape>${jvar_this_test_plan}</g:no_escape>
</div>
Thanks,
Dan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-24-2020 10:56 AM
Hey Dan,
Thanks again for your help, this seemed to fix the issue in most places. Still need to dig into our UI Macros to find exactly where this is happening but this helped a lot!