Response.Write("<script>alert('新闻更新成功!');location.replace('MyNews.aspx');</script>");
我的更新页面是在框架里边的,现在我想在更新成功以后跳转到另外一个页面,就是跳出框架,我想用target="_top",但是不知道怎么写 script.请大家帮忙,谢谢.

解决方案 »

  1.   

    Response.Write("<script>alert('新闻更新成功!');Parent.location.href=('MyNews.aspx');</script>");
      

  2.   

    你这个代码放进去没有执行,只执行了alert这个,后边没有执行.
      

  3.   

    function loadtwo() {  parent.frame1.location.href= "first.htm";  parent.frame2.location.href= "second.htm";}
      

  4.   

    Response.Write("<script>alert('新闻更新成功!');parent.框架名称.location.href= 'MyNews.aspx';</script>");
      

  5.   

    Response.Write("<script>alert('新闻更新成功!');top.location.href= 'MyNews.aspx';</script>");
      

  6.   

    Page.RegisterClientScriptBlock("transfer","<script language=javascript>self.parent.parent.location.href='WebForm01_06.aspx'</script>");
      

  7.   

    Response.Write("<script>alert('新闻更新成功!');window.open('MyNews.aspx','_top')</script>");