主题:  为什么不出现滚动条

楚楚

职务:普通成员
等级:1
金币:1.0
发贴:187
#12005/1/26 15:03:13
<a onClick="centerWindow('reply.asp?l_id=<%=rstopic2("id")%>','post','703','192','scrollbars=yes')">回复留言</a> 


为什么不出现滚动条?写了'scrollbars=yes'还是没有。



缺缺

职务:管理员
等级:8
金币:41.0
发贴:9620
#22005/1/26 15:05:23
修改你的centerWindow函数
scrollbars=yes是window.open的参数



楚楚

职务:普通成员
等级:1
金币:1.0
发贴:187
#32005/1/26 15:26:42
这是函数,请指教如何出现滚动条:

<script language="javascript" type="text/javascript">
<!--
function centerWindow(theURL,winName,width,height,features) {
var window_width = width;
var window_height = height;
var edfeatures= features;
var window_top = (screen.height-window_height)/2;
var window_left = (screen.width-window_width)/2;
newWindow=window.open(''+ theURL + '',''+ winName + '','width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ',features=' + edfeatures + '');
newWindow.focus();
}

//-->
</script>



{ 在指尖上绽放的花朵 }

职务:普通成员
等级:5
金币:14.0
发贴:3209
#42005/1/26 15:28:47
引用:
<script language="javascript" type="text/javascript">
<!--
function centerWindow(theURL,winName,width,height,features) {
var window_width = width;
var window_height = height;
var edfeatures= features;
var window_top = (screen.height-window_height)/2;
var window_left = (screen.width-window_width)/2;
newWindow=window.open(''+ theURL + '',''+ winName + '','width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ',features=' + edfeatures + ',scrollbars=yes' + '');
newWindow.focus();
}

//-->
</script>



楚楚

职务:普通成员
等级:1
金币:1.0
发贴:187
#52005/1/26 15:33:46
感谢两位高手。



楚楚

职务:普通成员
等级:1
金币:1.0
发贴:187
#62005/1/26 15:39:58
再请教一下,能否改进一下,让可以选择。比如:
<a onClick="centerWindow('reply.asp?l_id=<%=rstopic2("id")%>','post','703','192','scrollbars=no')">回复留言</a>
就不出现。

现在不管怎样都出现滚动条。



{ 在指尖上绽放的花朵 }

职务:普通成员
等级:5
金币:14.0
发贴:3209
#72005/1/26 15:49:36
引用:

<script language="javascript" type="text/javascript">
<!--
function centerWindow(theURL,winName,width,height,features,scrollbar) {
var window_width = width;
var window_height = height;
var edfeatures= features;
var scrollbar = scrollbar;
var window_top = (screen.height-window_height)/2;
var window_left = (screen.width-window_width)/2;
newWindow=window.open(''+ theURL + '',''+ winName + '','width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ',features=' + edfeatures + ',scrollbars=' + scrollbar+ '');
newWindow.focus();
}

//-->
</script>



<a onClick="centerWindow('reply.asp?l_id=<%=rstopic2("id")%>','post','703','192','','yes')">