简体   繁体   English

IE responseXML getelementsbytagname

[英]IE responseXML getelementsbytagname

if (xmlRequest.status == 200) 
if (xmlRequest.responseXML)
var xmlElement = xmlRequest.responseXML.getElementsByTagName("item"); 
rest of codes

The parsing working all except internet explorer. 解析工作正常,但Internet Explorer除外。

what should the var xmlElement be when its returning is null for internet explorer? 对于Internet Explorer,当var xmlElement返回null时,应该是什么?

var xmlElement = xmlRequest.responseXML ... ? var xmlElement = xmlRequest.responseXML ...?

When responseXML is returning null, that normally means there is an error with the XML. 当responseXML返回null时,通常意味着XML出错。

Are you sure that the document returned is valid XML? 您确定返回的文档是有效的XML吗?

Open up the response directly in the browser, if there is an error, the browser will point you to it. 直接在浏览器中打开响应,如果有错误,浏览器将指向您。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM