Jakoś niedawno spotkałem się z ciekawym zachowaniem właściwości ContentType na obiekcie HttpRequest. Najlepiej pokaże to prosty przykład. private void ProcessResponse(object sender, EventArgs e) { HttpContext context = ((HttpApplication)sender).Context; string contentType = context.Response.ContentType; if (context.Request.HttpMethod == “GET” && contentType.Equals(“text/html”) && context.Response.StatusCode == 200 && context.CurrentHandler != null) { context.Response.Filter = new RemoveWhitespaceFilterStream(context); } } Paweł ŁukasikFounder […]