if (!Request.UserAgent.ToLower().Contains("konqueror")) { if (Request.Headers["Accept-encoding"] != null && Request.Headers["Accept-encoding"].Contains("gzip")) { Response.Filter = new GZipStream(Response.Filter, CompressionMode.Compress, true); Response.AppendHeader("Content-encoding", "gzip"); } else if (Request.Headers["Accept-encoding"] != null && Request.Headers["Accept-encoding"].Contains("deflate")) { Response.Filter = new DeflateStream(Response.Filter, CompressionMode.Compress, true); Response.AppendHeader("Content-encoding", "deflate"); } }This code disconnection was accidentally found on the codeproject. It feels very good and I would like to share it with you. Request. userAgent. toLower (). contains ("konqueror") is used to filter out the konqueror browser. According to the original author, this browser may not support gzip and deflate well and has bugs. Here I also found a problem. If Response. BufferOutput is set to false, this code disconnection is not easy to use. You should pay attention to it when using it.