"<" ,">", symbol change to &lt; &gt; when apply template in agent workspace

Duy Nguyen Truo
Tera Contributor

Hello everyone! I have a question about apply template on Agent Workspace.
I'm using Utah version instance.
The  '<' (The greater than), '>' (The less than) symbols when I apply template it will change to "&lt;"  "&gt;". 
Is there any solution for this issue?
Hope everyone can help!
Thank you

DuyNguyenTruo_0-1684725148915.png

 

2 REPLIES 2

Sai Shravan
Mega Sage

Hi @Duy Nguyen Truo

This is a common behavior in HTML or XML, where these symbols are encoded for displaying as text rather than interpreted as tags. To resolve this issue, you can try using the raw syntax to prevent the conversion of these symbols. Instead of using "<" and ">", you can use their HTML entity representations: "<" and ">". By using the HTML entity codes, the symbols should be rendered correctly without being interpreted as tags.

<template>
  &lt;p&gt;This is a template code.&lt;/p&gt;
</template>

By using the HTML entity codes, the symbols will be displayed correctly when you apply the template.

 

Regards,

Shravan.

Please mark this as helpful and correct answer if this helps you

Regards,
Shravan
Please mark this as helpful and correct answer, if this helps you

BZSanchez
Tera Contributor

We got the same thing last weekend as well when we upgraded to Tokyo 7a. After searching the Known Error Portal I was able to find this: https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB1309211.

 

Hopefully this helps and they patch it soon. We have a lot of templates with symbols that also have HTML meanings in our Templates.