我需要返回http://service.semanticproxy.com/processurl/ftfu27m3k66dvc3r43bzfneh/html/http://www.smallbiztechnology.com/archive/2013/12/why-creating-a-digital-storefront-is-crucial-for-your-small-business.html本頁內容的完整的HTML頁面,但是當我調用該函數我需要返回使用Ajax調用
function getResult() {
var url="http://service.semanticproxy.com/processurl/ftfu27m3k66dvc3r43bzfneh/html/http://www.smallbiztechnology.com/archive/2013/12/why-creating-a-digital-storefront-is-crucial-for-your-small-business.html";
$.ajax({
cache: true,
url: url,
success: function (result) {
alert(result);
}
});
}
我的螢火得到這個:
段。 min.js(ligne 1) GET http://service.semanticproxy.com/processurl/ftfu...orefront-is-crucial-for-your-small-business.html 200 OK 379msA。
任何想法如何我可以得到該網頁的內容?
您正在運行相同的原產地策略。研究跨域AJAX。 –
該URL不允許來自不同域的請求,您需要在服務器上託管自己的代理腳本,以便下載並返回URL的內容。 –