解决方案 »

  1.   

    在网页上加上nocache头,客户端就不会缓存数据了
      

  2.   

    加入缓存和移除缓存
     //加入缓存
        protected void btnAddCache_Click(object sender, EventArgs e)
        {
            if (!string.IsNullOrEmpty(txtUserName.Text))
            {
                Cache.Insert("UserName", txtUserName.Text);
                txtMsg.Text = "目前UserName缓存内容为:" + Cache["UserName"].ToString();
            }
        }    //移除缓存
        protected void btnRemoveCache_Click(object sender, EventArgs e)
        {
            Cache.Remove("UserName");
        }
      

  3.   

    ajax请求的连接后面带一个随机数/?rd=+ Math.random()
      

  4.   

    应该还是我的代码有问题吧,我试着在网站里用vs里用现有模型类添加了一个新的控制器,模板用包含读写操作和视图的MVC控制器(使用entity faramework).人家很正常,可是我看代码和视图也没什么特殊的处理,请高手指点.我再加20分吧