[問題] ie在responseXML

看板Ajax作者 (踢恩)時間17年前 (2008/08/25 22:07), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
responseXML.documentElement=null responseXML.getElementById事件錯誤 我上網查是說response的文件要加header 不過那個頁面是api我不能改... 有什麼辦法可以解決嗎 firefox是可以這樣做 if(request.overrideMimeType){ request.overrideMimeType('text/xml'); } 求解答 謝謝 剛剛試了一下 var xmlDoc=new ActiveXObject("Microsoft.XMLDOM"); xmlDoc.async="false"; xmlDoc.loadXML(request.responseText); 也不能 var str='<?xml version="1.0" encoding="UTF-8"?>'+request.responseText; xmlDoc.loadXML(str); 還是不能 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 218.211.217.211 ※ 編輯: tn801534 來自: 218.211.217.211 (08/25 22:57) ※ 編輯: tn801534 來自: 218.211.217.211 (08/25 23:55)
文章代碼(AID): #18ihorCy (Ajax)
文章代碼(AID): #18ihorCy (Ajax)