2013-03-06 42 views
1

我新的闪存,我有一个Flash(.swf文件)文件显示通过WSDL方法我的数据库的内容。当它被加载,我可以看到我的数据,但它显示了一些错误,当它试图通过自身的内部刷新Flash对象。如何访问内部闪存的外部数据?

我使用Eclipse进行开发,Tomcat的7 Web服务器。

而且我已经把crossdomain.xml的在/根文件夹中,我能够通过点击

"http://localhost:8080/crossdomain.xml" 

(Note : 1. Both web service and flash file are running in the same server. 
     2. This error occurs only before accessing any data from server, once data is accessed the error is not generating anymore) 

当flash文件试图刷新自己显示通过网络浏览器的crossdomain.xml内容,它显示了跟随错误。

- >

To access external data, add a cross-domain policy file to the external data web server. 



For more information, on the Adobe website, see the article "Cross-domain Policy File Specification". 



If the problem persists, contact the file creator or your system administrator. 


Error: Error #2032 

Connection Type: Web Service 

File URL: http://localhost:8080/StudentService/performance.swf 

External Data URL: http://localhost:8080/StudentService/services/StudentService 

回答

0

尝试添加到端口属性和允许-http请求报头-从元件这样的..

<?xml version="1.0"?> 
<!DOCTYPE cross-domain-policy SYSTEM 
"http://www.adobe.com/xml/dtds/cross-domain-policy.dtd"> 

<cross-domain-policy> 
    <site-control permitted-cross-domain-policies="master-only"/> 
    <allow-access-from domain="*" to-ports="*" secure="false"/> 
    <allow-http-request-headers-from domain="*" headers="SOAPAction"/> 
</cross-domain-policy> 

感谢。

@Leo。

+0

感谢您的努力,但是很遗憾,我仍得到相同的错误:(。 – 2013-03-06 16:52:13

+0

嘿,我发现多了一个问题,这个错误只发生访问来自web服务的任何数据之前,访问来自web服务的任何数据后,错误不显示 – 2013-03-06 17:35:26