ASP.NET 使用response.redirect( "url ")跳转后,页面记录没刷新。
2011-07-07 10:15
1171 查看
如果是使用“本页提交,本页显示”的话,使用response.redirect( "url ")是可以刷新记录的,如果是使用“本页提交,另页显示”的话,使用response.redirect( "url ")就有可能页面记录不能自动刷新!
解决办法:
1、
response.write ("<script>")
response.write ("alert('xxx')")
response.write ("window.location='xxx.aspx'")
response.write ("<script>")
alert('xxx'); 相当于延迟了一上。
2、response.write (<meta http-equiv='refresh' content='0.1;url=http://www.dreamershop.com'>)
用这个可以做一个处理数据成功的提示页面,1秒以后跳转也可以。
解决办法:
1、
response.write ("<script>")
response.write ("alert('xxx')")
response.write ("window.location='xxx.aspx'")
response.write ("<script>")
alert('xxx'); 相当于延迟了一上。
2、response.write (<meta http-equiv='refresh' content='0.1;url=http://www.dreamershop.com'>)
用这个可以做一个处理数据成功的提示页面,1秒以后跳转也可以。
相关文章推荐
- ASP.NET MVC 里redirectMode="ResponseRewrite" 时候无法使用 Controller 来设置特定的错误页面。
- 如何使用 asp.net 4.0 新特性 路由功能 有助于seo优化 给一个 asp.net web项目(网站项目) 增加路由功能 ,继承,给根据路由生成的url的结尾,增加一个有利于seo优化的斜杠 /,跳转到一个路由生成的url页面
- ASP.NET中,页面刷新后跳转到刷新前的位置 MaintainScrollPositionOnPostback属性的使用
- js_html_input中autocomplete="off"在chrom中失效的解决办法 使用JS模拟锚点跳转 js如何获取url参数 C#模拟httpwebrequest请求_向服务器模拟cookie发送 实习期学到的技术(一) LinqPad的变量比较功能 ASP.NET EF 使用LinqPad 快速学习Linq
- 在ASP.NET中使用Response.ContentType="类型名";来确定输出格式
- ASP.NET刷新页面的六种方法(转) 包括在跳转的时候使用提示
- 在ASP.NET中使用Response.ContentType="类型名";来确定输出格式
- asp.net mvc中在Filter中跳转千万不要使用Response.Redirect
- ASP.NET页面跳转Response.Redirect抛出异常
- ASP.NET------Server.Transfer(),Response.Redirect()和PostBackUrl的跨页面Postback效果比较
- ASP.NET MVC之"重定向/页面跳转"(关键词RedirectToAction,Redirect)
- asp.net mvc中在Filter中跳转千万不要使用Response.Redirect[转]
- 在ASP.NET中使用Response.ContentType="类型名";来确定输出格式
- asp.net 页面跳转 Response.Redirect和Server.Transfer
- Asp.Net中Response.Redirect、Server.Transfer、PostBackUrl以及超链接引导页面的区别
- asp.net知识汇总-页面跳转Server.Transfer和Response.Redirect
- ASP.NET中使用 Response.Write("<script>alert('****');</script>");后CSS界面发生变化的解决方法 (经验证)
- C# ASP.NET中无刷新页面 弹出对话框,并且页面跳转
- ASP.NET页面跳转,定时刷新方法集合
- 关于ASP.NET MVC中Response.Redirect和RedirectToAction的BUG (跳转后继续执行后面代码而不结束进程)以及处理方法