将新打开的窗口放置在页面中间window.open

来源:互联网 发布:敏捷网络 编辑:程序博客网 时间:2024/05/16 18:24
function OpenWindow(){var height = 500;var width = 200;var top=Math.round((window.screen.height-height)/2);var left=Math.round((window.screen.width-width)/2);window.open("${path}/input/budgetFeeTypeDialog.jsp", "", "height=" + height + ", width=" + width + ", top=" + top + ", left= " + left + ", toolbar=no, menubar=no, scrollbars=auto, resizable=no, location=yes, status=no");}

height =500;

width=200;

这两个是设置的新页面的大小。其他的不多说明上一篇讲了!