title: onClick event not firing correctly
body: <p>I am using ASP.NET 4.0 and C#. I am attempting to do some validation on the client side before the data is submitted.</p>
  
  <p>Here is the javascript:</p>
  
  <pre><code> function Validate() 
        {
          alert('Validating');
        // validation occurs...
        //...etc
         }
  </code></pre>
  
  <p>Here is my asp control:</p>
  
  <pre><code>&lt;asp:Button ID="btnSubmit" runat="server" Text="Submit" CssClass="button" OnClientClick= "return Validate();" OnClick="BtnSubmit_Click" Enabled="True" /&gt;
  </code></pre>
  
  <p>finally here is the html that is rendered:</p>
  
  <pre><code>&lt;input type="submit" name="ctl00$masterMain$btnSubmit" value="Submit" onclick="return Validate();" id="masterMain_btnSubmit" class="button" /&gt;
  </code></pre>
  
  <p>Here is the kicker. The validation is working perfectly on my local machine through VS2010. However, after I move the code to DEV or UAT it the "Validate()" event will not fire. There is a lot of other javascript code which does work but for some reason this event does not fire properly. Anybody have a clue as to why? I have been trying to understand why it works locally but not on the servers. </p>