用
javascript实现框架之间的链接导航
框架为上中下,中间又分为左右型框架,现在想在左边框架单击按钮后,右边框架就实现导航链接,有两种方案:
1.直接用超级链接来实现,指定它的target,target的值为右边框架的名字。
框架代码:
<frameset rows="188,*,35" cols="*" frameborder="NO" border="0" framespacing="0" style="margin:0; width:100%; padding:0;" >
<frame name="banner" scrolling="no" noresize src="banner.aspx" frameborder="0">
<frameset rows="*" cols="150,8,*" frameborder="NO" border="0" framespacing="0" id="frame2">
<frame name="leftmenu" scrolling="auto" noresize src="menu.aspx" frameborder="0">
<frame name="callleftmenu" scrolling="no" noresize src="callleftmenu.html" frameborder="0">
<frame name="main" scrolling="auto" src="mytable.aspx" frameborder="0">
</frameset>
<frame name="status_bar" scrolling="no" noresize src="status_bar.aspx" frameborder="0">
</frameset>
<noframes></noframes>
主框架的名字为main,调用:<a class="cspbItm" href="http://www.cn-web.com" target="main">单击这里在右边显示啦</a>
parent.frames["main"].location.href="admin_xx.aspx";
OK。