{"id":14788,"date":"2017-09-12T15:00:23","date_gmt":"2017-09-12T14:00:23","guid":{"rendered":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/?page_id=14788"},"modified":"2017-09-12T15:00:23","modified_gmt":"2017-09-12T14:00:23","slug":"cross-origin-resource-sharing-cors","status":"publish","type":"page","link":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/cross-origin-resource-sharing-cors\/","title":{"rendered":"Cross-Origin Resource Sharing (CORS)"},"content":{"rendered":"<p>By default, for security reasons, browsers enforce a <a href=\"http:\/\/en.wikipedia.org\/wiki\/Same-origin_policy\" target=\"_blank\" rel=\"noopener\">same origin policy<\/a> where javascript can only access data from the same site (domain) that it is hosted on.\u00a0 In InstantAtlas Online apps this causes issues as the code is hosted on online.instantlas.com but the data can come from ArcGIS Online, any other ArcGIS map servers or csv files.\u00a0 Modern browsers now support CORS which is a specification that enables data access across different domains.<\/p>\n<p>ArcGIS Online servers already have CORS enabled on them but your own ArcGIS Servers or other ones may not. It is a simple process to do this on your own server as described on <a href=\"http:\/\/enable-cors.org\/\" target=\"_blank\" rel=\"noopener\">enable-cors.org<\/a>.\u00a0 GeoWise has built a useful <a href=\"http:\/\/online.instantatlas.com\/iao-dashboard-builder\/cors\" target=\"_blank\" rel=\"noopener\">CORS testing tool<\/a> which will tell you whether a particular web server already has CORS enabled on it.<\/p>\n<p>Note that Internet Explorer 9 does not support CORS.\u00a0 If your end users are going to be using this browser you will need to get GeoWise to register the map services you want to use with our proxy service.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>By default, for security reasons, browsers enforce a same origin policy where javascript can only access data from the same site (domain) that it is hosted on.\u00a0 In InstantAtlas Online apps this causes issues as the code is hosted on online.instantlas.com but the data can come from ArcGIS Online, any other ArcGIS map servers or &hellip; <a href=\"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/cross-origin-resource-sharing-cors\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Cross-Origin Resource Sharing (CORS)<\/span><\/a><\/p>\n","protected":false},"author":51,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-14788","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/pages\/14788","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/users\/51"}],"replies":[{"embeddable":true,"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/comments?post=14788"}],"version-history":[{"count":0,"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/pages\/14788\/revisions"}],"wp:attachment":[{"href":"https:\/\/help.instantatlas.com\/dashboard-builder-agol\/wp-json\/wp\/v2\/media?parent=14788"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}