<?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 CORS error on Print in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234875#M79444</link>
    <description>&lt;P&gt;CORS yet again - totally fed up now with this.&lt;/P&gt;&lt;P&gt;I HAVE to use API 3.11 - see&amp;nbsp;&lt;A href="https://community.esri.com/t5/arcgis-api-for-javascript-questions/measure-tool-no-longer-gives-result-on-mouse-move/m-p/1005139#M70923" target="_blank"&gt;Re: Measure Tool no longer gives result on mouse M... - Esri Community&lt;/A&gt; &amp;nbsp;due to a bug in the measure tool.&lt;/P&gt;&lt;P&gt;We are migrating to a new server so having fun with CORS, yet again.&lt;/P&gt;&lt;P&gt;Everything works until I try to print.&amp;nbsp; Then I get&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;esri.config.defaults.io.proxyUrl is not set. If making a request to a CORS enabled server, please push the domain into esri.config.defaults.io.corsEnabledServers&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;No hint as to WHAT domain needs pushing.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;This works if I go to the latest 3.x api.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So, I listed out what is in&amp;nbsp;corsEnabledServers in the latest api and compared with what I had in 3.11 and pushed all the others in.&amp;nbsp; Still nothing.&amp;nbsp; Although I couldn't work out how to push '/^https?:\/\/.+\.arcgis\.com(\/|$)/i, ' which is present in the latest version.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any ideas?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Cheers&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;BR /&gt;ACM&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 24 Nov 2022 13:33:38 GMT</pubDate>
    <dc:creator>AdrianMarsden</dc:creator>
    <dc:date>2022-11-24T13:33:38Z</dc:date>
    <item>
      <title>CORS error on Print</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234875#M79444</link>
      <description>&lt;P&gt;CORS yet again - totally fed up now with this.&lt;/P&gt;&lt;P&gt;I HAVE to use API 3.11 - see&amp;nbsp;&lt;A href="https://community.esri.com/t5/arcgis-api-for-javascript-questions/measure-tool-no-longer-gives-result-on-mouse-move/m-p/1005139#M70923" target="_blank"&gt;Re: Measure Tool no longer gives result on mouse M... - Esri Community&lt;/A&gt; &amp;nbsp;due to a bug in the measure tool.&lt;/P&gt;&lt;P&gt;We are migrating to a new server so having fun with CORS, yet again.&lt;/P&gt;&lt;P&gt;Everything works until I try to print.&amp;nbsp; Then I get&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;esri.config.defaults.io.proxyUrl is not set. If making a request to a CORS enabled server, please push the domain into esri.config.defaults.io.corsEnabledServers&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;No hint as to WHAT domain needs pushing.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;This works if I go to the latest 3.x api.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So, I listed out what is in&amp;nbsp;corsEnabledServers in the latest api and compared with what I had in 3.11 and pushed all the others in.&amp;nbsp; Still nothing.&amp;nbsp; Although I couldn't work out how to push '/^https?:\/\/.+\.arcgis\.com(\/|$)/i, ' which is present in the latest version.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any ideas?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Cheers&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;BR /&gt;ACM&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Nov 2022 13:33:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234875#M79444</guid>
      <dc:creator>AdrianMarsden</dc:creator>
      <dc:date>2022-11-24T13:33:38Z</dc:date>
    </item>
    <item>
      <title>Re: CORS error on Print</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234880#M79445</link>
      <description>&lt;P&gt;Oh - and to make this even more annoying this error only happens the FIRST time I make a request to the CustomPrint service - if I try a second time it is fine!&lt;/P&gt;</description>
      <pubDate>Thu, 24 Nov 2022 13:55:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234880#M79445</guid>
      <dc:creator>AdrianMarsden</dc:creator>
      <dc:date>2022-11-24T13:55:36Z</dc:date>
    </item>
    <item>
      <title>Re: CORS error on Print</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234898#M79446</link>
      <description>&lt;P&gt;OK - sorted - sort of.&lt;/P&gt;&lt;P&gt;I asked myself what was different the second time around?&amp;nbsp; I even trapped the error, and in error routine called the print service again (this didn't work) but when I added a&amp;nbsp;&lt;SPAN&gt;console.log(esri.config.defaults.io.corsEnabledServers) when the print function was called the second time it had one extra site in it - and this was the crucial one, in my case it was gisserver.fully.qualifed:6443 - pushing that in at startup sorts stuff&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Nov 2022 15:46:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/cors-error-on-print/m-p/1234898#M79446</guid>
      <dc:creator>AdrianMarsden</dc:creator>
      <dc:date>2022-11-24T15:46:34Z</dc:date>
    </item>
  </channel>
</rss>

