Why doesn't jquery .load() load a text file from an external website?

前端 未结 2 739

In the example below, when I click the button, it says \"Load was performed\" but no text is shown.

I have a clientaccesspolicy.xml

2条回答
  •  借酒劲吻你
    2021-01-07 12:40

    I don't think any browser obeys clientaccesspolicy.xml or crossdomain.xml for XMLHttpRequest.

    There are other mechanisms you can look at, such as Cross-Origin Resource Sharing. This is supported by Firefox 3.5 and later.

提交回复
热议问题