
一:刷新本页面
前台:window.location.href=window.location.href; script>
后台:Response.Write("window.location.href=window.location.href; script>")
二:刷新父页面
前台:opener.location.href=opener.location.href; script>
后台:Response.Write("opener.location.href=opener.location.href; script>")
三:链接到指定网页
前台:window.location.href='http://www.gxlcms.com'; script>
MSDN说的window.navigate(sURL)方法是针对IE的,不适用于FF,在HTML DOM Window Object中,根本没有列出window.navigate方法。
后台:Response.Write("window.location.href='yourpage.aspx'; script>")
或者: Response.Write("NewUrl");
四:刷新Iframe
前台:iframe名字或者ID.location.reload(true); script>
五:定时刷新
function flash(){window.location.href="http://www.gxlcms.com";setTimeout("flash()",1000);} //1000为一秒
setTimeout("location.href=http://www.gxlcms.com",2000) script>
setTimeout("self.location.reload();",1000);一秒一次