David B
01/24/2022, 4:44 AMrenderer.renderAsString()
is escaping special characters (like &
to &
), but is not escaping them in production (which causes a "SSS_XML_DOM_EXCEPTION" error when you call xml.validate(…)
).
I'm using identical xml templates, and the same code (see below)David B
01/24/2022, 4:54 AMxml.escape(xmlStr)
, as this escapes everything, not just the values (all the gt/lt brackets <>
)
I've created a plaintext file here, but was originally creating/saving as an xml file.
My only thought/fallback is to use a regex replace like:
xmlStr.replaceAll(/&(?!amp;)/g, '&');
battk
01/24/2022, 4:57 AMbattk
01/24/2022, 5:05 AM