SecurityError: Error #2048: 安全沙箱冲突:
 

问题是:在程序没发布时,直接运行没错误,但是当发布时,访问就错了,提示SecurityError: Error #2048: 安全沙箱冲突:http://localhost/XX.swf 不能从 http://localhost/ArcGIS/rest/services/MapServer 加载数据。

在安装.net arcgis后,C:\Inetpub\wwwroot\ArcGis\rest\的下面有个crossdomain.xml,把这个文件复制到C:\Inetpub\wwwroot的下面就可以了。

crossdomain.xml文件,内容如下:

<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
<allow-access-from domain="*" />
<allow-http-request-headers-from domain="*" headers="*"/>
</cross-domain-policy>

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-15
  • 2021-06-16
  • 2021-12-14
猜你喜欢
  • 2022-02-20
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案