title: Auto submit MVC form with jQuery when drop downs change not working
body: <p>I wonder if someone can shed some light why my form would not submit with the following script.  I need the from to submit as soon as the drop-down changed.</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  $(document).ready(function () {
      $("select").change(function () {
          $("#sform").submit(); // Trigger form load
          //alert('form to reload!');
      });
  
  });
  </code></pre>
  
  <p></p>
  
  <p>And the form something like this:</p>
  
  <pre><code>@using (Html.BeginForm("ServiceNumbers", "Home", FormMethod.Post, new { id = "sform" }))
  {
    &lt;div&gt; Companies:
      @Html.DropDownListFor(model =&gt; model.CompanyID, Model.CompaniesList, "")
    &lt;/div&gt;
  }
  </code></pre>
  
  <p>The commented out alert triggers when uncommented, the form itself does not submit.  I am obviously doing something wrong, or maybe this cannot work for some reason?  Related posts have not shed any light so far, still searching.</p>
  
  <p>Thanks in advance.</p>
  
  <p><strong>EDIT:</strong></p>
  
  <p>I tried most of the items in <a href="https://stackoverflow.com/questions/3752134/jquery-submit-form">this</a> post.  None seems to work.</p>
  
  <p>I can make the whole form disappear with:</p>
  
  <pre><code>$(document).ready(function () {
      $("select").change(function () {
          //$("form#sform").submit(); // Trigger form load
          //alert('form to reload! len=' + $("#sform").length);
          //document.forms["sform"].submit();
          //document.sform.submit();
          $("form#sform").html("");
      });
  </code></pre>
  
  <p>But submit - no way.  The only conclusion I can get to is that it has something to do with the MVC <em>modernizr-1.7.min.js</em> script.</p>