In internet explorer we can create the object of ActiveXObject like follows
xmlDoc=new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async="false";
xmlDoc.load("note_error.xml");
It is possible to use the xmlDoc.load(“note_error.xml”); for the object of XMLHttpRequest in other browsers.If no,any other substitute for this method when we use XMLHttpRequest.Please help…am using firefox as my browser
That’s not doing what you think.
asyncis a boolean property. When you assign the string"false"to it, you’re getting the valuetrue, because all non-empty strings are truthy.Yes, in fact that’s what you should be doing in IE too. There is no reason to use
XMLDOMto fetch an XML Document; XMLHttpRequest can do that fine and it’s much more widely supported.If you do need an
XMLDOM-like object in other browsers, it’s callednew DOMParser, but it’s not as widely-supported asXMLHttpRequest.