我无法强制页面始终在Safari中过期. Chrome,IE和Firefox都是很好的公民,但Safari正在巡航,忽略了以下ASP.NET代码:
- // Expire immediately
- Response.Expires = 0;
- Response.Cache.SetNoStore();
- Response.AppendHeader("Pragma","no-cache");
有什么建议?
解决方法
信不信由你,让Safari总是重新加载页面的方法只是将其添加到body标签:
- onunload=""
我在这里找到了这个:Is there a cross-browser onload event when clicking the back button?