Tuesday, June 26, 2007

"Warning Page has expired" message in IE

The message "Warning. Page has expired" is a common occurrence in many sites if you click on the Back button of the browser. When this happens, the user has to refresh the page in order to see the contents of the page. Can be quite annoying.


Reasons behind this message:


·         This message appears when the browse cache is disabled

·         The page that the user is going back to was a result of a “POST”. So, in fact, the browser does not automatically “resubmit” the data again. It shows a warning, and makes the user explicitly re-submit again in order to fetch the data. This is the way browsers handle this possible security risk. Firefox displays a “Page cannot be found” error instead.


It is important to understand the difference between:



Cross Page Postback (using PostBackUrl) property.

Please refer to this link to know more about these three techniques of page transfer:


How it is relevant in this particular case is:


·         Response.Redirect does a “GET”, where as, the other two techniques actually use the “POST” query. This means, if a page had been reached by doing any of the Server.Transfer or PostBackUrl will show the “Warning. Page Expired” message on click on the Browser Back button if cache is disabled.


·         Where as, any page that was reached by a Response.Redirect will not cause this warning message to appear when it is re-visited using the Browser Back button.


Whether the browser cache should be disabled or not is a different issue – which depends more on the content of the pages in your application. If the pages contain dynamic data, there is no option but to disable the browser cache. And when you do that, you start seeing the Warning Page Expired messages very often.



Thanks & Regards,

Arun Manglick

SMTS || Microsoft Technology Practice || Bridgestone - Tyre Link || Persistent Systems || 3023-6258


DISCLAIMER ========== This e-mail may contain privileged and confidential information which is the property of Persistent Systems Pvt. Ltd. It is intended only for the use of the individual or entity to which it is addressed. If you are not the intended recipient, you are not authorized to read, retain, copy, print, distribute or use this message. If you have received this communication in error, please notify the sender and delete all copies of this message. Persistent Systems Pvt. Ltd. does not accept any liability for virus infected mails.

No comments:

Post a Comment