xiaoer_1982 发表于 2013-2-7 15:22:30

Response.Redirect在新窗口打开的另一种方法

这里是孟子提供的方法
这里介绍Ihttpmodule处理请求管道的方法。Response.Redirect的原理是服务器设置返回http状态码为302,然后客户端执行跳转,用reflector可以看到.net的代码段。
以下是HttpResponse类的Redirect方法中的跳转代码
<div style="padding-right: 5.4pt; padding-left: 5.4pt; background: #e6e6e6; padding-bottom: 4px; width: 95%; padding-top: 4px;">http://images.csdn.net/syntaxhighlighting/OutliningIndicators/None.gifthis.StatusCode=0x12e;
http://images.csdn.net/syntaxhighlighting/OutliningIndicators/None.gifthis.RedirectLocation=url;
页: [1]
查看完整版本: Response.Redirect在新窗口打开的另一种方法