JessyEzzy wrote:
Quote:
I want to disable page caching so that when a user presses the
browser's back button after submitting a form, he won't be able to
re-edit the form.
How can I do that? |
Short answer: You can't. Caching and backward navigation are
conceptually unrelated, as far as the HTTP spec is concerned.
Long answer: Many Browsers actually *do* apply caching instructions to
back/forward navigation. The standard way of disabling caching is
either to set the OutputCache directive on your page(s)
<%@ OutputCache Location="None" %>
or to set the Cache property of the HttpResponse in your code file:
Response.Cache.SetCacheability(HttpCacheability.No Cache);
(which is equivalent to the directive shown above).
Cheers,
--
http://www.joergjooss.de
mailto:news-reply (AT) joergjooss (DOT) de