一言不合 直接传代码 :)
var openVideo = null;
function openCarVideo(vehType,camIdnum){var url = rootPath + "/gis/video?vehType="+vehType+"&camIdnum="+camIdnum;
var iWidth=1910; //弹出窗口的宽度; 1260
var iHeight=1070; //弹出窗口的高度;610
//var iTop = (window.screen.availHeight-30-iHeight)/2; //获得窗口的垂直位置;
var iTop = 0;
var iLeft = 0;
//var iLeft = (window.screen.availWidth-10-iWidth)/2; //获得窗口的水平位置;
if(openVideo != null){
openVideo.close();
}else{
openVideo = null;
}
openVideo = window.open(url, "newwindow", "height="+iHeight+", width="+iWidth+", top="+iTop+", left="+iLeft);
openVideo.focus();
}