How to send Cache-Control: no-cache in HTTP Response header?
问题 Net 4 and C#. I would need set send to Browser Cache-Control ( Cache-Control: no-cache ) in the HTTP Response header for a Web Form page. Any idea how to do it? Thanks for your time. 回答1: Try this: Response.AppendHeader("Cache-Control", "no-cache"); However, you should know that this header alone won't give you a reliable cross-browser way to prevent caching. See this answer for more accurate solution: Making sure a web page is not cached, across all browsers 回答2: In MVC you can set it in the