responseXML.documentElement error en Internet Explorer
Bueno, pues haciendo una aplicacion en AJAX, estoy intentando cargar un xml, pero al utilizar objetoAJAX.responseXML.documentElement en Internet Explorer, contiene 'null'. En FireFox funciona bien
Como lo puedo solucionar? gracias
PD: Asi creo el objetoAJAX
function objetus() {
var xmlhttp;
if (window.XMLHttpRequest) { // Mozilla, Safari,...
xmlhttp = new XMLHttpRequest();
if (xmlhttp.overrideMimeType) {
xmlhttp.overrideMimeType('text/xml');
// Ver nota sobre esta linea al final
}
} else if (window.ActiveXObject) { // IE
try {
xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
} catch (e) {
try {
xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
} catch (e) {}
}
}
return xmlhttp;
}
Como lo puedo solucionar? gracias
PD: Asi creo el objetoAJAX
function objetus() {
var xmlhttp;
if (window.XMLHttpRequest) { // Mozilla, Safari,...
xmlhttp = new XMLHttpRequest();
if (xmlhttp.overrideMimeType) {
xmlhttp.overrideMimeType('text/xml');
// Ver nota sobre esta linea al final
}
} else if (window.ActiveXObject) { // IE
try {
xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
} catch (e) {
try {
xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
} catch (e) {}
}
}
return xmlhttp;
}