如何获得和使用JavaScript设置如何获取和设置窗口弹出的高度和宽度在Internet Explorer
在Firefox中我能够设置高度和宽度使用outerHeight窗口弹出高度和宽度Internet Explorer中 ,窗口的outerWidth属性。
谢谢。
如何获得和使用JavaScript设置如何获取和设置窗口弹出的高度和宽度在Internet Explorer
在Firefox中我能够设置高度和宽度使用outerHeight窗口弹出高度和宽度Internet Explorer中 ,窗口的outerWidth属性。
谢谢。
如果它是一个现有的窗口,您可以设置使用window.resizeTo
(MSDN link)大小:
window.resizeTo(640, 480)
或者,您可以指定大小时,窗口的存在使用window.open
方法(MSDN link)创建:
window.open ("http://stackoverflow.com",
"mywindow","location=1,status=1,scrollbars=1,
width=640,height=480");
window.open('something.html','new_win','width=320,height=240');