Pop-up Window - centred : Dialog : Window Browser JAVASCRIPT DHTML TUTORIALS


JAVASCRIPT DHTML TUTORIALS » Window Browser » Dialog »

 

Pop-up Window - centred



<html>
<head>
<title>Pop-up</title>

<script language="javascript">
<!--

function PopupWin(page,IEWidth,IEHeight,NNWidth,NNHeight) {

  var MyBrowser = navigator.appName;

  if (MyBrowser == "Netscape") {
  var myWinWidth = (window.screen.width/2(NNWidth/2);
  var myWinHeight = (window.screen.height/2((NNHeight/250);

  var myWin = window.open(page,"MainWin","width=" + NNWidth + ",height=" + NNHeight + ",screenX=" + myWinWidth + ",screenY=" + myWinHeight + ",left=" + myWinWidth + ",top=" + myWinHeight + ",scrollbars=yes,toolbar=0,status=1,menubar=0,resizable=0,titlebar=no");

  }else {
  var myWinWidth = (window.screen.width/2(IEWidth/2);
  var myWinHeight = (window.screen.height/2((IEHeight/250);

  var myWin = window.open(page,"MainWin","width=" + IEWidth + ",height=" + IEHeight + ",screenX=" + myWinWidth + ",screenY=" + myWinHeight + ",left=" + myWinWidth + ",top=" + myWinHeight + ",scrollbars=yes,toolbar=0,status=1,menubar=0,resizable=0,titlebar=no");

  }
  myWin.focus();

}
//-->
</script>
</head>
<body>
<a href="javascript:PopupWin('http://www.navioo.com',300,400,300,400)">New Window</a><br>
</body>
</html>



           
       



-

Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .

Follow Navioo On Twitter

JAVASCRIPT DHTML TUTORIALS

 Navioo Window Browser
» Dialog