title: how to create button click event for form method?
body: <p>I have Form tag in my layout page. I cant use form tags in content page, so I am using Form method="post" how to create button click event for this and how to give validation for html input type?</p>
  
  <pre><code>&lt;form class="contact-form-title white" method="post"&gt;
      &lt;label id="lblFirstName" runat="server" title="First Name:"&gt;First Name:&lt;/label&gt;
      &lt;input type="text" id="txtFirstNam" runat="server"  /&gt;&lt;br /&gt;
  
      &lt;label id="lblLastName" runat="server" title="Last Name:"&gt;Last Name:&lt;/label&gt;
      &lt;input type="text" id="txtLastNam" runat="server"  /&gt;&lt;br /&gt;
  
      &lt;label id="lblEmail" runat="server" title="Email ID:"&gt;Email ID:&lt;/label&gt;
      &lt;input type="text" id="txtEmail" runat="server"  /&gt;
  
      &lt;label id="lblMessage" runat="server" title="Message"&gt;Message:&lt;/label&gt;
      &lt;textarea id="txtMessag" runat="server" &gt;&lt;/textarea&gt;&lt;br /&gt;                          
      &lt;input type="submit" class="btn delicious f-center" runat="server" id="btnContac" name="SUBMIT" onserverclick="btnContac_Click" style="height:25%; width:10%;"/&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Back-End :</p>
  
  <pre><code>protected void Page_Load(object sender, EventArgs e)
  {
  
  }
  
  protected void btnContac_Click(object sender, EventArgs e)
  {
     string FirstName = txtFirstNam.Value;
     string LastName = txtLastNam.Value;
     string EmailID = txtEmail.Value;
     string Message = txtLastNam.Value;
  }
  </code></pre>