Ok, I might be missing something so please forgive me.
If you are able to have succcess with the zlib library, then you 90%
done, you just need to look at the return header from the server.
your request should look like this (edit as needed)
$hHOST = "www.somedomain.com"; // the domain name for the page
$hURI = "/page_to_get.html"; // the page you want
$hREF = "http://mysite.com/was"; // in case you need the referer
$hAGENT = "My fuzzy web bot v1.0"; // the name of the user agent
(browser), IE or Netscape, etc..
$header = "GET $hURI HTTP/1.1" .
. "Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, "
. "application/vnd.ms-powerpoint, application/vnd.ms-excel,
application/msword, "
. .application/x-shockwave-flash, */*\n"
. "Host: $hHOST\n"
. "Referer: $hREF \n"
. "User-Agent: $hAGENT\n"
. "Accept-Encoding: gzip\n"
. "Accept-Language: en-us\n"
. "Connection: Close\n"
. "\n";
now send the $header string to the server after you connect to it,
then look for this line from the server
"Content-Encoding: gzip"
if you find gzip in the encoding header that the server sends back,
then it is sending back encoded data, otherwise it did not encode it.
I hope this help.
Mike Bradley
http://gzen.myhq.info -- free online php tools