码迷,mamicode.com
首页 > 其他好文 > 详细

arcserver 跨域问题

时间:2015-07-28 07:59:46      阅读:95      评论:0      收藏:0      [点我收藏+]

标签:

http://resources.arcgis.com/en/help/rest/apiref/config.html#jcrossOriginAccess
http://enable-cors.org/server_iis7.html

跨域问题:
XMLHttpRequest cannot load http://10.19.1.59/ArcGIS/rest/services/mapWGS/MapServer/?f=json. No ‘Access-Control-Allow-Origin‘ header is present on the requested resource. Origin ‘null‘ is therefore not allowed access.

http://forums.arcgis.com/threads/78905-GeometryServic-Buffer-Task-amp-Access-Control-Allow-Origin?p=277900#post277900 4楼

II7
在服务器端 C:\Inetpub\wwwroot\ArcGIS\rest\Web.Config 和 C:\Inetpub\wwwroot\ArcGIS\Services\Web.Config 中添加以下段落
<system.webServer>
    <httpProtocol>
      <customHeaders>
        <add name="Access-Control-Allow-Origin" value="*"/>
      </customHeaders>
    </httpProtocol>
</system.WebServer>
II6
IIS下ArcGIS右键‘属性‘,‘HTTP头‘在‘自定义HTTP头‘中添加头名‘Access-Control-Allow-Origin‘,值‘*‘

arcserver 跨域问题

标签:

原文地址:http://www.cnblogs.com/messipapa/p/4681725.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!