When you request a website with the header
The website can return with the header
And proceed to send the HTML content compressed using gzip. I already have a project that retrieves HTML content from websites, but I need to be able to unzip the gzipped content into readable HTML. There are several utilities out there to unzip a file, however I want to unzip this content without using a file - Id like to unzip it within the program, unzip the content that is stored in a string.
There are lots of resources out there that you can use to make this happen, so it should not be a difficult thing. It can be done in any language (except .NET) providing it is FAST and that I can use the function to unzip the string via a dll or something.
This is how your function should look (pseudocode):
Function unZip (inString as String) as String
'Your Code Here that takes inString which is zipped HTML, checks it to ensure the data is not corrupt or anything, and output the uncompressed version of that string
my code: unzippedString = unZip(theHTMLcontentThatIsZippedWithGzip)
An example of the server response that needs to be unzipped is attached.