title: how to add confirm box before submit buttons?
body: <p><strong>adding confirm box</strong></p>
  
  <p>Here is my code and I want to add a confirmation box to it.</p>
  
  <p>I have a form with two <code>submit</code> buttons. I need the confirmation box with them and then send to the next page. How can I do this?
          this is the code for confirmation box,how can i place it in my form ?</p>
  
  <pre><code>onclick="return confirm('Are you sure?');"
  </code></pre>
  
  <p>myform.jsp</p>
  
  <pre><code>&lt;form id="form1" name="form1" method="post" action=""&gt;
      &lt;p&gt;&amp;nbsp;&lt;/p&gt;
      &lt;p align="center"&gt;Enter your choice:-
      &lt;label&gt; &lt;br /&gt;
      &lt;label&gt;
         &lt;input type="submit" name="Submit" value="delete" onclick="this.form.action='logi.jsp?flag=1&amp;act=1';this.form.submit();" /&gt;
      &lt;/label&gt;
      &lt;br /&gt;
      &lt;/br&gt;
      &lt;label&gt;
          &lt;input type="submit" name="Submit" value="Delete" onclick="this.form.action='delete1.jsp?flag=1&amp;act=1';this.form.submit();" /&gt;
      &lt;/label&gt;
      &lt;br/&gt;
      &lt;/div&gt;
  &lt;/form&gt;
  </code></pre>