Silverlight中的跨域问题 [英] cross domain issue in silverlight

查看:50
本文介绍了Silverlight中的跨域问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在用W.C.F搜索银色光下的横截面问题
我有类似
的代码

i am searching about Cross Section issue in silver light with W.C.F
i have code like

<?xml version="1.0" encoding="utf-8" ?>
<access-policy>
   <cross-domain-access>
      <policy>
       <allow-from http-request-headers="SOAPAction,Content-Type">
          <domain uri="*" />
         </allow-from>
         <grant-to>
          <resource path="/" include-subpaths="true"/>
         </grant-to>
    </policy>
   </cross-domain-access>
</access-policy>
Point to be noted in this file
   1. Check out element http-request-headers="SOAPAction... ". Normally when you download this file and save it without changing. File will content (*) in place of SOAPAction (Highlighted in above code). Make sure to change it to SOAPAction.
   2. Save clientaccesspolicy.xml to   c:\Inetpub\wwwroot


上一行显示将文件保存在c:\ Inetpub \ wwwroot</pre>中.
它将在本地但在服务器上如何工作.
以及我将保存上述文件的位置


但是它可以在本地系统上运行.
在IIS和实时服务器上不起作用
请帮助我
这将是极大的帮助
谢谢您


the above line show save the file in c:\Inetpub\wwwroot</pre>
it will works on local but on server how it done.
and where i will save the above file


but it is works on local system .
it is not working on IIS and live server
plz help me
it will be greate help
thanks you

推荐答案

请确保将文件放置在承载Silverlight应用程序的域的根目录的物理文件夹中. c:\ Inetpub \ wwwroot并不总是正确的位置.

还要确保XML是服务器上受支持的MIME类型(在IIS上默认为默认).

您可以使用Fiddler之类的工具查看文件是否正在下载.如果不是,则问题出在服务器端.
Make sure you are placing the file in the physical folder for the root of the domain the Silverlight app is hosted on. c:\Inetpub\wwwroot is not always the correct place.

Also make sure XML is a supported MIME type on the server (should be by default on IIS).

You can use something like Fiddler to see if the file is being downloaded. If it''s not, the problem is on the server end.


这篇关于Silverlight中的跨域问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆