我們當前想要在ajax加載更多後加載廣告。但是,該廣告調用響應包含document.write,並在調用完成後重定向到廣告本身。沒有辦法只獲取ad html並追加它。所以我們必須在ajax成功中處理document.write。我看到了關於iframe的一些內容,但並不知道我應該如何實現它。ajax成功的廣告調用響應包含document.write
$.ajax({
.
.
.
success: function(response) {
var loadedAd = ad call here; -- but it redirects to the ad itself due to the document.write in ad response.
謝謝。
你應該告訴我們,AJAX返回的響應。 –