title: Unobtrusive Validation Not Fired
body: <p>I have a MVC3 view, local debug perfectly fine, after I deployed to server I found unobtrusive validation is not fired at all.</p>
  
  <p>I saved the output to a static HTML file and get rid all unnecessary codes and with following section remaining</p>
  
  <pre><code>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
  &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
  &lt;head&gt;&lt;title&gt;
  
      Dummy
  
  &lt;/title&gt;
      &lt;link type="text/css" href="/Content/site.css" rel="stylesheet" /&gt;
      &lt;script type="text/javascript" src="/Scripts/jquery-1.6.4.js"&gt;&lt;/script&gt;
      &lt;script type="text/javascript" src="/Scripts/jquery.validate.js"&gt;&lt;/script&gt;
      &lt;script type="text/javascript" src="/Scripts/jquery.validate.unobtrusive.js"&gt;&lt;/script&gt;
      &lt;script type="text/javascript" src="/Scripts/jquery.unobtrusive-ajax.js"&gt;&lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;form action="/Test/Dummy" data-ajax="true" data-ajax-complete="MyDummy.OnComplete" data-ajax-method="Post" id="form0" method="post"&gt;
  &lt;select data-val="true" data-val-number="The field SourceId must be a number." data-val-required="SourceId required." id="SourceId" name="SourceId"&gt;&lt;/select&gt;
  &lt;span class="field-validation-valid" data-valmsg-for="SourceId" data-valmsg-replace="true"&gt;&lt;/span&gt;&lt;br /&gt;
  
  &lt;select data-val="true" data-val-number="The field DestinationId must be a number." data-val-required="DestinationId required." id="DestinationId" name="DestinationId"&gt;&lt;/select&gt;
  &lt;span class="field-validation-valid" data-valmsg-for="DestinationId" data-valmsg-replace="true"&gt;&lt;/span&gt;&lt;br /&gt;
  
  &lt;input type="submit" value=" Submit " class="ButtonStyle" /&gt;
  &lt;/form&gt;
  
  &lt;script type="text/javascript"&gt; 
      var MyDummy = {
          OnComplete: function (content) {
              alert(content.responseText);
          }
      }
  &lt;/script&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>I believe I have included proper JavaScript files, all the rendered Html looks fine to me. When I click on the submit button I expect validation message, but instead the oncomplete event fires.</p>
  
  <p>I am very lost here, anybody has clue what is wrong?</p>
  
  <p><strong>Edit 1</strong>, I copied the same static Html file to my local project's folder and access it via <a href="http://localhost:48194/test.htm" rel="nofollow">http://localhost:48194/test.htm</a> (my local ASP.NET Development Server) and everything works fine. But if I load the same file from 2008 server's local IE8 at <a href="http://localhost:87/test.htm" rel="nofollow">http://localhost:87/test.htm</a> (IIS 7) then I got the issue. Somehow it leads me to think is there something wrong setting IIS7 which blocks or partially blocks the access to JavaScript files properly?</p>
  
  <p><strong>Edit 2</strong>, 
  If I change the JS reference to use CDN like</p>
  
  <pre><code>&lt;script type="text/javascript" src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.6.4.js"&gt;&lt;/script&gt; 
  &lt;script type="text/javascript" src="http://ajax.aspnetcdn.com/ajax/jquery.validate/1.9/jquery.validate.js"&gt;&lt;/script&gt; 
  &lt;script type="text/javascript" src="http://ajax.aspnetcdn.com/ajax/mvc/3.0/jquery.validate.unobtrusive.js"&gt;&lt;/script&gt; 
  &lt;script type="text/javascript" src="http://ajax.aspnetcdn.com/ajax/mvc/3.0/jquery.unobtrusive-ajax.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>Then it works. I really don't know now what IIS7 could do to damage the local JS file transportation.</p>