jsp中的window.open和window.showModalDialog的弹出页面以及传参

1、window.open弹出页面,页面高宽和位置的确定。

window.open('../pmp/project_safety!getProjectPage.action?falg=2','newwindow','width=693,height=550,menubar=no,toolbar=no,location=no,directories=no,status=no,scrollbars=yes,resizable=yes,top='+(screen.height-500)/2+',left='+(screen.width-500)/2+'')





2、window.showModalDialog弹出模态页面,url多个参数传递

window.showModalDialog('../pmp/project_safety!getProjectPage.action?projectIds='+idStr+'&falg='+Str+'','','resizable:yes;scroll:no;status:no;dialogWidth=680px;dialogHeight=480px;center=yes;help=no'); 


 3、window.showModalDialog去掉水平(横向)滚动条

   在弹出页面的body中添加样式style="overflow:scroll;overflow-x:hidden"(去掉纵向滚动条style="overflow:scroll;overflow-y:hidden")



 

你可能感兴趣的:(jsp中的window.open和window.showModalDialog的弹出页面以及传参)