title: Opening a link onclick html
body: <p>So, i am creating this webpage, that opens another page in the same directory on the click of a button.
  While doing so, I observed something which I couldn't find an satisfactory explanation to.
  The button code I am using is this</p>
  
  <pre><code>&lt;a class="class1" href="webpage2.html"&gt;&lt;button type="button"&gt;Button1&lt;/button&gt;&lt;/a&gt;
  </code></pre>
  
  <p>this seems to work, but not this,</p>
  
  <pre><code>&lt;button type="button"&gt;&lt;a class="class1" href="webpage2.html"&gt;Button1&lt;/a&gt;&lt;/button&gt;
  </code></pre>
  
  <p>Why is this so? (Am I missing something very simple?)</p>