caycot

<HTML>
          <HEAD>
          <script type="text/javascript">
          function show_confirm ()
          {
          var r=confirm ("Are you sure?");
          if  (r==true)
            {
            document.write("You pressed OK!");
            }
           else
            {
            window.close ();
            }
            }
          </script>
          </HEAD>
          <body>
          
          </body><input type="button" onclick="show_confirm ()" value="Show a confirm box" />
          </HTML>

caycot

<HTML>
          <HEAD>
          <script type="text/javascript">
          function show_confirm ()
          {
          var r=confirm ("Are you sure?");
          if  (r==true)
            {
            document.write("You pressed OK!");
            }
           else
            {
            window.close ();
            }
            }
          </script>
          </HEAD>
          <body>
          
          </body><input type="button" onclick="show_confirm ()" value="Show a confirm box" />
          </HTML>