title: No client side password matching on MVC view
body: <p>I have the following (abridged) DTO for registering a new user:</p>
  
  <pre><code>[PropertiesMustMatch("Password", "ConfirmPassword", ErrorMessage = "The password and confirmation password do not match.")]
  public class RegisterModel
  {
      //.....
      [DataType(DataType.Password)]
      public string Password { get; set; }
      [DataType(DataType.Password)]
      public string ConfirmPassword { get; set; }
  }
  </code></pre>
  
  <p>This is then wrapped in a View Model as such:</p>
  
  <pre><code>public class RegisterModelViewData: BaseViewData
  {
      public RegisterModel RegisterModel { get; set; }
      public int PasswordLength { get; set; }
  }
  </code></pre>
  
  <p>And finally, on the view, I have the two fields as such:</p>
  
  <pre><code>&lt;div class="editor-field"&gt;
      &lt;%= Html.PasswordFor(m =&gt; m.RegisterModel.Password) %&gt;
      &lt;%= Html.ValidationMessageFor(m =&gt; m.RegisterModel.Password) %&gt;
  &lt;/div&gt;
  &lt;div class="editor-field"&gt;
      &lt;%= Html.PasswordFor(m =&gt; m.RegisterModel.ConfirmPassword) %&gt;
      &lt;%= Html.ValidationMessageFor(m =&gt; m.RegisterModel.ConfirmPassword) %&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Apparently, I am supposed to get a client side validation, and no post, if the passwords don't match.  I get a post and then a message that "Account creation wAs unsuccessful", but nothing about mismatched passwords.  I have omitted the Required and MininumLength attributes from the password proeprties here for brevity, but they seem to behave as expected and validate on the client.</p>