Re: Request help parsing XML reply from HTTPRequest
- From: spambait@xxxxxxxxxx (Doug Miller)
- Date: Wed, 26 Sep 2007 17:53:21 GMT
In article <46fa816b$0$16109$9b4e6d93@xxxxxxxxxxxxxxxxxxxxxxxxxxx>, Martin.Honnen@xxxxxx wrote:
Doug Miller wrote:
Client side is IE6 / Win XP Pro SP2. I have no idea what the server sidehave
environment is. It doesn't belong to me, I have no control over it, and I
to take what I can get.
Do you simply want to load an XML document and parse it with IE 6?
No -- I'm sending an HTTP request to a remote server, and I need to parse the
XML response that the server returns.
Then you don't need XMLHttpRequest, instead you can do e.g.
var xmlDocument = new ActiveXObject('Msxml2.DOMDocument.3.0');
xmlDocument.onreadystatechange = function () {
if (xmlDocument.readyState === 4) {
alert(xmlDocument.getElementsByTagName('package').length);
}
};
xmlDocument.load('file.xml');
XMLHTTP and responseXML will only work if the server sends the XML with
the HTTP response header Content-Type with value text/xml or
application/xml.
And if it doesn't?
--
Regards,
Doug Miller (alphageek at milmac dot com)
It's time to throw all their damned tea in the harbor again.
.
- References:
- Request help parsing XML reply from HTTPRequest
- From: Doug Miller
- Re: Request help parsing XML reply from HTTPRequest
- From: Thomas 'PointedEars' Lahn
- Re: Request help parsing XML reply from HTTPRequest
- From: Doug Miller
- Re: Request help parsing XML reply from HTTPRequest
- From: Thomas 'PointedEars' Lahn
- Re: Request help parsing XML reply from HTTPRequest
- From: Doug Miller
- Re: Request help parsing XML reply from HTTPRequest
- From: Martin Honnen
- Request help parsing XML reply from HTTPRequest
- Prev by Date: Re: Request help parsing XML reply from HTTPRequest
- Next by Date: Strange behaviour, multiplying decimals (IE)
- Previous by thread: Re: Request help parsing XML reply from HTTPRequest
- Next by thread: Re: Request help parsing XML reply from HTTPRequest
- Index(es):
Relevant Pages
|