<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
<head><meta forua="true" http-equiv="Cache-Control" content="max-age=0" /></head>
<card title="asp.net禁止页面缓存，适合各种浏览器" id="card1">
<p> 游客</p><p>
标题:asp.net禁止页面缓存，适合各种浏览器<br/>
正文:<br/>
客户端：&amp;lt;html&amp;gt; &amp;lt;head&amp;gt; &amp;lt;meta http-equiv=&amp;quot;Expires&amp;quot; CONTENT=&amp;quot;0&amp;quot;&amp;gt; &amp;lt;meta http-equiv=&amp;quot;Cache-Control&amp;quot; CONTENT=&amp;quot;no-cache&amp;quot;&amp;gt; &amp;lt;meta http-equiv=&amp;quot;Pragma&amp;quot; CONTENT=&amp;quot;no-cache&amp;quot;&amp;gt; &amp;lt;/head&amp;gt;服务器端：Response.Buffer = true;Response.ExpiresAbsolute = DateTime.Now.AddDays(-1);Response.Cache.SetExpires(DateTime.Now.AddDays(-1));Response.Expires = 0;Response.CacheControl = &amp;quot;no-cache&amp;quot;;Response.Cache.SetNoStore();Global： protected void Application_BeginRequest(Object sender, EventArgs e){ HttpContext.Current.Response.Cache.SetNoStore(); }&amp;lt;%@ OutPutCache Location=&amp;quot;None&amp;quot;%&amp;gt; ASP.NETResponse.Cache.SetCacheability(HttpCacheability.NoCache);ASP:[在.net下也行]Response.Expires = 0;Response.Buffer = true;Response.ExpiresAbsolute = DateTime.Now.AddSeconds(-1);Response.AddHeader(&amp;quot;pragma&amp;quot;, &amp;quot;no-cache&amp;quot;);Response.CacheControl = &amp;quot;no-cache&amp;quot;;//也就是通过禁止缓存，来实现重新刷新，这样页面即使在遇到back，也会自动刷新<br/><a href="http://camnpr.com/wap.asp?mode=WAP&amp;act=View&amp;id=288&amp;Page=1">[&lt;&lt;]</a><a href="http://camnpr.com/wap.asp?mode=WAP&amp;act=View&amp;id=288&amp;Page=1">[[1]]</a><a href="http://camnpr.com/wap.asp?mode=WAP&amp;act=View&amp;id=288&amp;Page=1">[&gt;&gt;]</a><br/>
<br/>
<a href="wap.asp?act=Com&amp;id=288">查看评论(0)</a><br/>
<a href="wap.asp?act=AddCom&amp;inpId=288">发表评论</a><br/><br/>

<br/>

<br/>
<a href="http://camnpr.com/wap.asp">首页</a>
</p>
</card>
</wml>