Silverlight的跨站策略和跨站策略文件
来源:互联网 发布:伪装地理位置软件哪个 编辑:程序博客网 时间:2024/06/07 20:09
如果我们需要在Silverlight中跨站调用Web Service,则可能会遇到这个问题:默认情况下,Silverlight是不允许你这么做的。那么如何来解决该问题呢,请看Tim下面的这篇文章
http://timheuer.com/blog/archive/2008/04/06/silverlight-cross-domain-policy-file-snippet-intellisense.aspx
简单而言,Silverlight并非不支持跨站调用,而是会首先检查一个文件clientaccesspolicy.xml 如果该文件找不到,则查找另外一个文件crossdomain.xml ,然后再找不到的话,就报告错误了
这个问题可以通过监视工具很简单地看出来
If you are starting to get into integrating web services with Silverlight, you'll notice that you have to have a cross domain policy file in place on the target server, that is to say, the server hosting the service you want to implement. There are some public web services (Flickr, YouTube, Digg, etc.) that already have these files in place for Flash, but implement in a slightly different way.
When calling a cross-domain service, Silverlight will check for the existence of clientaccesspolicy.xml first. This is the format defined by Silverlight and provides a pretty flexible way to define who can access what services. If not found, it will then default to look for crossdomain.xml, which is the file format implemented for Adobe Flash. It is important to note that this file will also still work for most public web services.
- Silverlight的跨站策略和跨站策略文件
- SilverLight跨域访问策略
- silverlight跨域策略(webservice)
- Silverlight跨域访问策略
- Silverlight 跨域调用策略
- 跨域策略文件
- Flex跨域策略文件
- flash跨域策略访问文件和socket
- flex解决跨域问题的策略文件的写法
- Flex解决跨域问题的策略文件的写法
- 跨域策略文件crossdomain.xml的配置方法
- 跨域策略文件crossdomain.xml的配置方法
- Silverlight访问Java Webservice策略文件安放位置
- 跨域策略文件--crossdomain.xml
- 跨域策略文件--crossdomain.xml
- 跨域策略文件crossdomain.xml配置
- 稳扎稳打Silverlight(53) - 4.0通信之对WCF NetTcpBinding的支持, 在Socket通信中通过HTTP检索策略文件, HTTP请求中的ClientHttp和Browse
- 稳扎稳打Silverlight(53) - 4.0通信之对WCF NetTcpBinding的支持, 在Socket通信中通过HTTP检索策略文件, HTTP请求中的ClientHttp和Browse
- hello,mono!
- RIA 亮剑行动
- Silverlight中的多语言支持中几个特殊之处
- Silverlight中使用自定义服务
- 你需要知道的隐式转换操作符
- Silverlight的跨站策略和跨站策略文件
- 根据方法名执行方法的例子
- 关于Thread.IsAlive属性
- 事件处理程序的处理顺序问题
- 支持取消操作和暂停操作的Backgroundworker
- 线程池(ThreadPool)
- SystemEvents和SystemEvents线程
- 默认情况下程序启动后到底是几个线程?
- 多线程的最佳实践