怎么才能控制要打开页面的大小

来源:百度知道 编辑:UC知道 时间:2024/09/21 13:32:00
现在的代码是对新的窗口固定宽高. 请问一下? 如何我不用弹出的新窗口,怎么固定原有窗口的宽高

function windowopen(){
var target="http://www.hongen.com"
newwindow=window.open("","","scrollbars","resizable=yes")
if (document.all){
newwindow.moveTo(0,0)
newwindow.resizeTo(screen.width,screen.height)
}
newwindow.location=target;
window.opener=null;
window.close();
}
【newwindow.moveTo(0,0) 】

<form method="post" action="a.asp" target="new_win" onSubmit="window.open('','new_win','width=300,height=200')">
<input type="text">
<input type="submit">
</form>
其中width是宽,height是高

<form method="post" action="a.asp" target="new_win" onSubmit="window.open('','new_win','width=300,height=200')"><