页面缓存怎么这样子

zhengyingcan zhengyingcan 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
protected void Page_Load(object sender, EventArgs e)
{
Application["hello"] = "欢迎学习APPLI对象";
this.TextBox1.Text = this.Application["hello"].ToString();
this.Label1.Text = this.Application["hello"].ToString();
this.Label2.Text = this.Session.SessionID.ToString();
}
我先前的代码如上,IE上的结果是我想要的结果,我把代码改成如下:
protected void Page_Load(object sender, EventArgs e)
{
//Application["hello"] = "欢迎学习APPLI对象";
//this.TextBox1.Text = this.Application["hello"].ToString();
//this.Label1.Text = this.Application["hello"].ToString();
//this.Label2.Text = this.Session.SessionID.ToString();
}
里面的代码全部注释掉,结果输出一样的结果,我问了一下高人,这是为何,回答说是页面缓存 , 难道页面缓存是为了干错误的事情吗.
...全文
评论 20
收藏 已收藏
分享
返回顶部
zhengyingcan
.NET社区 62,272 成员 668,968 内容