var newWin;function openNewWindow(page){    if (null != newWin && !newWin.closed) closeNewWindow();        newWin=window.open(page,'','width=300,height=300,scrollbars=yes,resizable=yes,screenX=0,screenY=0,top=0,left=0,status=yes,menubar=yes,directories=yes,location=yes,toolbar=yes');    newWin.focus();}function openNewWindowFullControl(page,width,height,scrollbars,resizable,screenX,screenY,top,left,status,menubar,directories,location,toolbar){    if (null != newWin && !newWin.closed) closeNewWindow();    var props = 'width=' +width +',height=' +height +',scrollbars=' +scrollbars +',resizable=' +resizable  +',screenX=' +screenX +',screenY=' +screenY +',top=' +top +',left=' +left +',status=' +status +',menubar=' +menubar +',directories=' +directories +',location=' +location +'toolbar=' +toolbar;    newWin=window.open(page,'',props);    newWin.focus();}function openNewWindowWH(page, width, height){   if (null != newWin  && !newWin.closed)  closeNewWindow();   var props = 'width=' +width +',height=' +height +',scrollbars=yes,resizable=yes,screenX=0,screenY=0,top=0,left=0,status=yes,menubar=yes,directories=yes,location=yes,toolbar=yes';    newWin=window.open(page,'',props);    newWin.focus();}function closeNewWindow(){   newWin.close();   this.focus();}