<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic 4.14 HTML in popupTemplate not rendering in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/4-14-html-in-popuptemplate-not-rendering/m-p/294396#M27010</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In previous versions, I created a popuptemplate with &amp;lt;h1&amp;gt;, &amp;lt;img&amp;gt;, and other HTML elements. In 4.14, it looks like a TextContent in the popupTemplate should support that same type of content. So, I create the popupTemplate with something like this:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="language-javascript line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt; content&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt; type&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"text"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; text&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; x &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;x is an html string with h1, h2, img, and table tags.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It appears that none of these html tags are rendering. the &amp;lt;h1&amp;gt; and similar tags are printed on the screen as raw text. the img source is just empty, where it should be a base64 representation of a png.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm not surprised that the img source is being scrubbed out, that seems like it might be done for security, but why won't the h1 tags render?&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 07 Jan 2020 21:32:59 GMT</pubDate>
    <dc:creator>CharlieElverson</dc:creator>
    <dc:date>2020-01-07T21:32:59Z</dc:date>
    <item>
      <title>4.14 HTML in popupTemplate not rendering</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/4-14-html-in-popuptemplate-not-rendering/m-p/294396#M27010</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In previous versions, I created a popuptemplate with &amp;lt;h1&amp;gt;, &amp;lt;img&amp;gt;, and other HTML elements. In 4.14, it looks like a TextContent in the popupTemplate should support that same type of content. So, I create the popupTemplate with something like this:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="language-javascript line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt; content&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt; type&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"text"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; text&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; x &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;x is an html string with h1, h2, img, and table tags.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It appears that none of these html tags are rendering. the &amp;lt;h1&amp;gt; and similar tags are printed on the screen as raw text. the img source is just empty, where it should be a base64 representation of a png.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm not surprised that the img source is being scrubbed out, that seems like it might be done for security, but why won't the h1 tags render?&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Jan 2020 21:32:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/4-14-html-in-popuptemplate-not-rendering/m-p/294396#M27010</guid>
      <dc:creator>CharlieElverson</dc:creator>
      <dc:date>2020-01-07T21:32:59Z</dc:date>
    </item>
    <item>
      <title>Re: 4.14 HTML in popupTemplate not rendering</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/4-14-html-in-popuptemplate-not-rendering/m-p/294397#M27011</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please see the reason and workaround for this from &lt;A _jive_internal="true" href="https://community.esri.com/thread/246072-why-are-my-classes-being-removed-when-using-popuptemplate"&gt;here&lt;/A&gt;.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;-Undral&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Jan 2020 23:01:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/4-14-html-in-popuptemplate-not-rendering/m-p/294397#M27011</guid>
      <dc:creator>UndralBatsukh</dc:creator>
      <dc:date>2020-01-07T23:01:04Z</dc:date>
    </item>
  </channel>
</rss>

