Response.Write("<script>window.top.location.href='index.aspx'</script>");出错,为什么??? Page.RegisterStartupScript("首页", "<script>openNwin=window.open('index.aspx','_blank','width=425,height=208 ,fullscreen=0,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=0')</script>"); 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 Response.Write("<script>window.top.location.href='");Response.Write("\'");Response.Write("\index.aspx");Response.Write("\'");Response.Write("<");Response.Write("/");Response.Write("script>"); 上面有问题,试试这个Response.Write("<script>window.top.location.href=");Response.Write("\'");Response.Write("\index.aspx");Response.Write("\'");Response.Write("<");Response.Write("/");Response.Write("script>"); Response.Write("<script>window.top.location.href='index.aspx'</script>");这句看起来没有错误 用这个试RegisterStartupScript可能是脚本在对象产生前就执行了 先注册一下 试试这一句:Response.write("<script>window.opener.location.href='index.aspx';</script>"); Response是PAGE的属性所以你不能在离开PAGE的地方使用 应该是:Response.Write( "<script>window.top.location.href='index.aspx'</" + "script>" ); 如果是c#的注意转义字符,把那些字符转下,如果是vb的就可以直接写了。 Response.Write("<script>window.top.location.href='index.aspx'</script>"-------------------------------------------------------------------------------Response.Write("<script>window.top.location.href='index.aspx';</script>"); c#.net 页面之间通信的方法 求大神解答下怎么把XML节点元素的值赋值给lab标签 求现在比较流行实用的.net开发模式 asp.net连接ACESS出现 .Net Framework 数据提供程序要求 (MDAC), 请安装(MDAC) 2.6 或更高版本 关于数据绑定后的Server.UrlEncode编码问题 大家进来看看,哪位兄弟做过这方面的研究? 如何判断TextBox控件文本的宽度(中文字要用两位计算)? 页面打印 能解决这个问题的就是神!! 有没有什么好的asp.net编辑工具呀? 可以用验证控件验证datagrid吗? 妹妹告急 ~~~ TABLE如何删除列? 急
Response.Write("\'");
Response.Write("\index.aspx");
Response.Write("\'");
Response.Write("<");
Response.Write("/");
Response.Write("script>");
Response.Write("<script>window.top.location.href=");
Response.Write("\'");
Response.Write("\index.aspx");
Response.Write("\'");
Response.Write("<");
Response.Write("/");
Response.Write("script>");
这句看起来没有错误
所以你不能在离开PAGE的地方使用
Response.Write( "<script>window.top.location.href='index.aspx'</" + "script>" );
-------------------------------------------------------------------------------
Response.Write("<script>window.top.location.href='index.aspx';</script>");