Can you please tell me what the is HTTP response code when we see a "Web page has expired" on the Internet Explorer?
相关问题
- Angular RxJS mergeMap types
- How to fix IE ClearType + jQuery opacity problem i
- Google Apps Script: testing doPost() with cURL
- How to instantiate Http service in main.ts manuall
- C#使用http访问网络,有办法用指定网卡访问网络嘛?
相关文章
- C#使用http访问网络,有办法用指定网卡访问网络嘛?
- Is a unicode user agent legal inside an HTTP heade
- IE/Edge not applying transform: translate to table
- Number of Javascript lines executed during page lo
- git: retry if http request failed
- Flutter - http.get fails on macos build target: Co
-
Is it bad to put elements within the <hea
- C# HttpClient.SendAsync always returns 404 but URL
查看全部
If you get this message it means you're returning to a page which you previously reached by submitting information, but the page has expired from the cache.
Internet Explorer doesn't want to just blindly re-submit your information, in case it has consequences (like a double charge on your credit card). So it displays this warning.
Either you pressed the refresh button, or the page will have expired from the cache due to some sort of Cache-Control directive on the server, such as "must-revalidate" in combination with "no-cache" or an "Expires" date that has expired.
You should look for
Cache-control:
header containingno-store
or
Cache-control:
header containingmust-revalidate
and
Cache-control:
header containingno-cache
or similaror
Expires:
header with a date that has expiredor
Something else which would make the cache unsatisfiable such as an overly restrictive
Vary:
header.A way to prevent this on the server-side is to use the Post/Redirect/Get strategy.
There's no specific response code associated with this. That's just a browser default error page when the enduser attempts to request a non-cached POST request from the browser history.
So, in order to get such an error page when the user browses back in the history, then the following two conditions have to be met:
It was a HTTP POST request (thus, not GET! else the browser will just re-send it to the server).
It has the minimum necessary response headers which have instructed the browser to not cache the response.