现在的位置: 首页 > 综合 > 正文

始终在屏幕中间弹出窗口

2012年11月03日 ⁄ 综合 ⁄ 共 274字 ⁄ 字号 评论关闭

function OpenWindow(url,width,height,name,options)
{
var left = (screen.width-width)/2;
var top = (screen.height-height)/2;
if(options ==null)
options ="";
var newWin =  window.open(url,name,"left=" +left+",top="+top+",width="+width+",height="+height+","+options);
newWin.focus();
return newWin;

}

抱歉!评论已关闭.