public static PhpValue ob_gzhandler(Context ctx, PhpValue data, int mode)
{
//// TODO: mode is not passed by Core properly. Therefore it is not possible to make subsequent calls to this handler.
//// Otherwise headers of ZIP stream will be mishmashed.
//// check input data
//if (data == null) return false;
//// check if we are running web application
//var httpcontext = ctx.TryGetProperty<HttpContext>();
//System.Collections.Specialized.NameValueCollection headers;
//if (httpcontext == null ||
// httpcontext.Request == null ||
// (headers = httpcontext.Request.Headers) == null)
// return data ?? false;
//// check if compression is supported by browser
//string acceptEncoding = headers["Accept-Encoding"];
//if (acceptEncoding != null)
//{
// acceptEncoding = acceptEncoding.ToLowerInvariant();
// if (acceptEncoding.Contains("gzip"))
// return DoGzipHandler(ctx, data, httpcontext, ContentEncoding.gzip);
// if (acceptEncoding.Contains("*") || acceptEncoding.Contains("deflate"))
// return DoGzipHandler(ctx, data, httpcontext, ContentEncoding.deflate);
//}
//return data ?? false;
throw new NotImplementedException(); // move to pchplib.web.dll
}