How to decompress/inflate an XML response from ASP
Posted
by krisg
on Stack Overflow
See other posts from Stack Overflow
or by krisg
Published on 2010-04-07T05:36:26Z
Indexed on
2010/04/07
5:43 UTC
Read the original article
Hit count: 371
Can anyone provide some insight into how i'd go about decompressing an XML response in classic ASP. We've been handed some code and asked to get it working:
Set oXMLHttp = Server.CreateObject("MSXML2.ServerXMLHTTP")
URL = HttpServer + re_domain + ".do;jsessionid=" + ue_session + "?" + data
oXMLHttp.setTimeouts 5000, 60000, 1200000, 1200000
oXMLHttp.open "GET", URL, false
oXMLHttp.setRequestHeader "Accept-Encoding", "gzip"
oXMLHttp.send()
if oXMLHttp.status = 200 Then
if oXMLHttp.responseText = "" then
htmlrequest_get = "Empty Response from Server"
else
htmlrequest_get = oXMLHttp.responseText
end if
else
...
Apparently now that the response is compressed using gzip, we have to un-compress the XML response before we can start to work with the data.
How should i go about this?
© Stack Overflow or respective owner