LiteralControl control1 = new LiteralControl("<base target=\"_self\">");
this.Header.Controls.Add(control1);
this.Response.Expires = 0;
具体什么意思不是很明白,反正就把缓存时间设置为0吧。。让下次页面开启的时候不去找缓存就好了this.Header.Controls.Add(control1);
this.Response.Expires = 0;
本文介绍了一段ASP.NET代码,该代码通过将响应的Expires属性设置为0来禁用页面缓存,确保每次页面加载时都不会使用缓存,这对于需要实时更新内容的网页非常有用。

445

被折叠的 条评论
为什么被折叠?



