2012-04-15 3 views
2

AJAX 요청을 디버깅하는 데 문제가 있습니다. (터널이므로 async입니다)IE 관련 AJAX 액세스 문제

어쨌든 Chrome과 Firefox에서는 잘 작동하지만 IE8/9에서는 실패합니다.

var responseA = ''; 

$.ajax({ 
    type: 'GET', 
    url: 'http://pipes.yahooapis.com/pipes/pipe.run?_id=xxxxxx&url=http%3A%2F%2Fwww.rottentomatoes.com%2Fm%2Fthe_hunger_games%2F&_render=json', 
    async: true, 
    dataType: 'json', 
    success: function(text) { 
     responseA = text; 
    }, 
    error: function(jqXHR, textStatus, errorThrown) { 
     console.log(errorThrown); 
    } 
}); 

console.log(responseA);​ 

errorThrown 내가 어떤 크로스 도메인 문제를 해결하려고 $.support.cors = true;

을 추가하는 시도 LOG: No Transport

을 던졌습니다하지만 지금은

LOG: Error: Access is denied. (만 IE에서) 무엇을주는거야?

+0

사용하려는 경우 (출력을 원격 스크립트를 호출하고 반환 동일한 도메인에서 PHP 스크립트를 통해) 프록시 자신의 요청이 도메인 간 AJAX 요청을 처리하려면'json' 대신'jsonp'의'dataType'을 지정해야합니다. –

+0

'async'와 함께 작동하지 않을 것이라고 읽었습니다. – Chamilyan

답변

1

인터넷 익스플로러 8 (아래) CORS를 지원하지 않습니다, 당신은