Open new window and write user text : Window External « Javascript Objects « JavaScript DHTML






Open new window and write user text

  



<html>
<head>
  
  <script type="text/javascript">
    function showBox() {
      userText = "My own browser text";
      if (userText != null) {
        userWindow = window.open("", "userTextWindow", "toolbar=0,width=200,height=200");
        userWindow.document.write(userText);
        userWindow.document.close();
      }
    }
  </script>
</head>
<body>
<form action="null" method="post">
    <input type="button" value="Go!" onclick="showBox()" />
</form>
</body>
</html>

   
    
  








Related examples in the same category

1.'AutoCompleteSaveForm()' Example
2.Add Favorite
3.'ImportExportFavorites()' Example
4.'IsSubscribed()' Example
5.'menuArguments' Example
6.Navigate And Find
7.'AutoScan()' Example