我现在有一个这样的问题,有一个home.aspx的页面,里面有两个iframe名字分别为A和B,我现在想在A的iframe页面里写一个跳转语句,可以让整个home页面都跳转而不是只是在A里面跳转,用this.Response.Redirect只是在A里面跳转。请各位帮帮忙,谢谢了。

解决方案 »

  1.   

    add <base targe="_top" /> to the head section of iframe.htm
      

  2.   

    Response.Write("<script language=javascript>window.parent.location.href='url'</script>")
      

  3.   

    Response.Write("<script language=javascript>window.open('你的页面,'_parent')</script>");
      

  4.   

    Response.Write("<script language=javascript>window.open('你的页面','_parent')</script>");
      

  5.   

    楼上的方法也可以,就是Response.write("<script>window.open('newwindows.aspx');</script>")
    或者用<a href="newwindows.aspx" Target="_blank">链接</a>
    不也可以吗?
      

  6.   

    楼主可以参考:http://www.cnblogs.com/renyu732/archive/2005/06/20/177745.html
      

  7.   

    Response.Write("<script>window.parent.location="aa.aspx"</script");
      

  8.   

    用window.parent.location真的可以也,谢谢各位了。