title: How do I stop my server side function from processing?
body: <p>I have an asp:button that calls a client side function. The client side function gives a confirmation asking if the user wants to proceed. I have returned false however it is still proceeding with the server side function. Why is my client side function not stopping the process?</p>
  
  <p>Here is my button:</p>
  
  <pre><code>&lt;asp:Button ID="btnSend" runat="server" Text="Send To Feed Mill" Height="36px"
                                  OnClick="btnSend_Click" OnClientClick="sendFeed_Click()" Visible="False" /&gt;
  </code></pre>
  
  <p>Here is my Javascript function:</p>
  
  <pre><code>    function sendFeed_Click() {
      $('.tonnage').each(function () {
          var maxTons = $(this).data("maxtons");
          if (this.value &gt; maxTons) {
              if (confirm("The order amount is more than the maximum. Are you sure you wish to continue?")) {
                  return true;
              } else {
                  return false;
              }
          }
      })
  }
  </code></pre>