I am using a Response.Filter. I am overriding the Write method. But I am observing that the Write method is executing many times and the response html in Write method come into chunked. How can I read(and then filter) the complete html in Write method.
Share
You should avoid doing this as it may have a performance impact on your website. Filters are streams, they are low-level, and meant for working directly with the response bytes, so are ideal for doing things like Gzip compression.
You should try and do your filter operations in chunks ideally. If you really can’t, you can write a filter based on a
MemoryStream. Remember you will be creating an in-memory buffer so be sure that your responses will be relatively short.