惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Google DeepMind News
Google DeepMind News
爱范儿
爱范儿
J
Java Code Geeks
L
LangChain Blog
V
V2EX
大猫的无限游戏
大猫的无限游戏
S
SegmentFault 最新的问题
博客园 - Franky
Microsoft Azure Blog
Microsoft Azure Blog
Jina AI
Jina AI
Blog — PlanetScale
Blog — PlanetScale
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
The Cloudflare Blog
博客园 - 司徒正美
B
Blog
G
Google Developers Blog
Stack Overflow Blog
Stack Overflow Blog
罗磊的独立博客
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Apple Machine Learning Research
Apple Machine Learning Research
Engineering at Meta
Engineering at Meta
MyScale Blog
MyScale Blog
有赞技术团队
有赞技术团队
Hugging Face - Blog
Hugging Face - Blog

博客园 - zjy

ligerui.grid.extend.rowSpan 用户中心 - 博客园 用户中心 - 博客园 OnClientClick 从通用分页存储过程[ROWCOUNT方式]抽出适合自己需求的分页过程 防SQL注入 用户中心 - 博客园 [CS0030错误]奇怪:难不成ChangePassword也是系统用名? DataTable中统计列中不同行问题 推荐个C#不错的开发工具(新版本SharpDevelop) 安装IE7 Visual Studio出现调试不够权限的解决办法 求助:UltraWebGrid当用xml paging(ajax)时,如何取其子表的band的index或者子表行信息?(NetAdvantage) 解决UltraWebGrid分页时出现的脚本错误(Infragistics的Bug) 解决infragistics的webgrid嵌套子表列名在ajax下(xml paging)出现的乱码问题 修改上传文件控件样式并实现上传文件功能 用页传值方式解决模态窗口的Response.WriteFile文件下载 DataTable添加列时容易被忽略的问题! 获取一个星期时间段的具体日期 Web导出Word需要添加头文件 - zjy - 博客园
重构oninit,应用在模式窗口的方法
zjy · 2006-08-23 · via 博客园 - zjy

因为用到模式窗口,所以在BasePage中重构ONINIT,用来去缓存和窗口的打开设置 :)

 1protected override void OnInit(EventArgs e)
 2        {
 3            System.Threading.Thread.CurrentThread.CurrentCulture = System.Globalization.CultureInfo.CreateSpecificCulture("zh-CN");
 4
 5            Response.Buffer = true;
 6            Response.ExpiresAbsolute = System.DateTime.Now.AddSeconds( -1 );
 7            Response.Expires = 0;
 8            Response.CacheControl = "no-cache";
 9
10            string style = "<link rel=\"stylesheet\" href=\"" + GlobalVar.CSSName + "\">\n"; //CSSName = "css/default.css"
11            style += "<base target=\"_self\">\n";
12            Response.Write(style);
13
14            string nocache = "<meta http-equiv=\"pragma\" content=\"no-cache\">\n";
15            nocache += "<meta http-equiv=\"cache-control\" content=\"no-cache, must-revalidate\">\n";
16            nocache += "<meta http-equiv=\"expires\" content=\"WED, 26 Feb 1997 08:21:57 GMT\">\n";
17            Response.Write(nocache);
18
19            this.Load += new System.EventHandler(this.BasePage_Load);
20        }

posted @ 2006-08-23 14:03  zjy  阅读(905)  评论(3)    收藏  举报

刷新页面返回顶部