一个页面调用另一个页面

来源:互联网 发布:britney spears 知乎 编辑:程序博客网 时间:2024/05/20 05:56

<table class="style1">
            <tr>
                <td style=" margin:0" class="style2">
                    <iframe height="768px" src="Left.aspx" style="width: 209px"></iframe></td>
                <td  style=" width:100%;">
                    <iframe height="768px" id="main" name="main" width="100%" src="MapIndex.aspx"></iframe></td>
            </tr>
        </table>

Left.aspx中使用

一个页面调用 另一个页面

Response.Write("<script> document.parentWindow.parent.document.getElementById('main').src='MapIndex.aspx?typeid=" + type + "'</script>");

一个页面调用另一个页面的方法

Response.Write("<script>window.parent.frames['main'].window.loadInfo();</script>");