100分!急!急!急!多窗口控制问题!
请教!!
多窗口控制,怎样动态改变多窗口(frames)中的某一个窗口的大小(横向或纵向。比如一页中有横向两个窗口,在左窗口中点击一个按钮可以把右边的窗口宽度改变为0或使之隐藏也可以,再点击另一按钮可使其恢复正常)。还有就是一页中有横向两个窗口,开始时是左窗口宽度为100%,右边的是0%,怎样实现在左边的窗口点击一个按钮使左右窗口比例变成80%和20%并定位到右边窗口的某一行?
感谢!!!
问题点数:100、回复次数:3Top
1 楼Equn(熠群)回复于 2003-11-02 17:55:16 得分 40
这个是控制脚本:
function switchSysBar(){
if (switchPoint.innerText==3){
switchPoint.innerText=4
//parent.document.all("frmTitle").style.display="none"
//alert(top.content.rows)
document.all("mnuList").style.display="none"
top.content.cols="10,*"
}
else{
switchPoint.innerText=3
document.all("mnuList").style.display=""
top.content.cols="150,*"
}
}
下面是frames代码,你自已参考参考吧:
<frameset name=forum rows="28,*" noresize scrolling="no" border=0 frameborder="0" bordercolor="white" framespacing="0" >
<frame name=title src="title.asp" noresize scrolling="no" >
<frameset name=content cols="150,*" noresize scrolling="no" border=0 frameborder="0" framespacing="0">
<frameset name=menu noresize scrolling="no" border=0 frameborder="0" framespacing="0" rows="20,*">
<frame name="BoardRefresh" noresize scrolling="no" src="">
<frame name="BoardTitle" noresize scrolling="no" target="BoardMenu" src="menu.asp">
</frameset>
<frame src="main.asp?boardid=1" name="BoardMain">
</frameset>
</frameset>
<noframes>
<body>
sorry ! your browser not support frame!
</body>
</noframes>Top
2 楼fason(咖啡人生)回复于 2003-11-02 18:00:01 得分 60
like CSDN here:
var strColumns_Current = "215,*";
function hidetoc()
{
strColumns_Current = top.mainframeset.cols
top.mainframeset.cols = "1,*";
top.contentbar.document.all("showtoc").style.display = "block";
}
function showtoc()
{
top.mainframeset.cols = strColumns_Current;
top.contentbar.document.all("showtoc").style.display = "none";
}
并定位到右边窗口的某一行
=============================
parent.frames["right"].document.body.scrollTop=100
or
use
parent.frames["right"].location.href="**.asp#a"
<a name=a>test</a>
Top
3 楼zhouguoyao(飞鸟)回复于 2003-11-02 21:21:01 得分 0
upTop




