| 
  
 <html>
 <head>
 <script type="text/javascript">
 var newWindow
 function openWindow() {
 var winAtts = new String()
 winAtts = "";
 
 if(document.winOptions.toolbarOption.checked){winAtts += "toolbar,"}
 if(document.winOptions.menubarOption.checked){winAtts += "menubar,"}
 if(document.winOptions.scrollbarsOption.checked){winAtts += "scrollbars,"}
 if(document.winOptions.resizableOption.checked){winAtts += "resizable,"}
 if(document.winOptions.statusOption.checked){winAtts += "status,"}
 if(document.winOptions.locationOption. checked){winAtts += "location,"}
 if(document.winOptions.directoriesOption.checked){winAtts += "directories,"}
 if(document.winOptions.copyHistoryOption.checked){winAtts += "copyhistory,"}
 if(document.winOptions.customSizeOption.checked){
 winAtts += "height=" + document.winOptions.heightBox.value + ",";
 winAtts += "width=" + document.winOptions.widthBox.value + ",";
 }
 winAtts = winAtts.substring(0, winAtts.length-1);
 if (document.winOptions.pageType[1].checked){
 var urlVar = ""
 urlVar = document.winOptions.urlBox.value
 newWindow = window.open(urlVar,"newWindow",winAtts)
 }else{
 newWindow = window.open("","newWindow",winAtts)
 newWindow.document.write("<h1>Window Open Test</h1>");
 newWindow.document.close();
 }
 }
 function closeWindow() {
 newWindow.close()
 }
 </script>
 </head>
 <body>
 <form name="winOptions" method="post" action="null">
 <input type="radio" checked="checked" name="pageType" value="existing" />Existing Page
 <input type="radio" name="pageType" value="dynamic" /> Dynamic Page
 <input type="text" size="30" maxlength="256" name="urlBox" />
 <input type="checkbox" name="toolbarOption" /> Toolbar
 <input type="checkbox" name="menubarOption" /> Menubar
 <input type="checkbox" name="scrollbarsOption" /> Scrollbars
 <input type="checkbox" name="resizableOption" /> Resizable
 <input type="checkbox" name="statusOption" /> Status
 <input type="checkbox" name="locationOption" /> Location
 <input type="checkbox" name="directoriesOption" /> Directories
 <input type="checkbox" name="copyHistoryOption" /> Copy History
 <input type="checkbox" name="customSizeOption" /> Custom Size
 Width:
 <input type="text" size="5" maxlength="5" name="widthBox" />
 Height:
 <input type="text" size="5" maxlength="5" name="heightBox" />
 <input type="button" name="OpenButton" value="Open Window" onclick="openWindow()" />
 <input type="button" name="CloseButton" value="Close Window" onclick="closeWindow()" />
 </form>
 </body>
 </html>
 
 
 
 
 |