title: MaxLength Attribute not generating client-side validation attributes
body: <p>I have a curious problem with ASP.NET MVC3 client-side validation. I have the following class:</p>
  
  <pre><code>public class Instrument : BaseObject
  {
      public int Id { get; set; }
  
      [Required(ErrorMessage = "Name is required.")]
      [MaxLength(40, ErrorMessage = "Name cannot be longer than 40 characters.")]
      public string Name { get; set; }
  }
  </code></pre>
  
  <p>From my view:</p>
  
  <pre><code>&lt;div class="editor-field"&gt;
      @Html.EditorFor(model =&gt; model.Name)
      @Html.ValidationMessageFor(model =&gt; model.Name)
  &lt;/div&gt;
  </code></pre>
  
  <p>And here's the generated HTML I get for the textbox for this field:</p>
  
  <pre><code>&lt;input class="text-box single-line" data-val="true" data-val-required="Name is required." id="Name" name="Name" type="text" value=""&gt;
  </code></pre>
  
  <p>No sign of the <code>MaxLengthAttribute</code>, but everything else seems to be working.</p>
  
  <p>Any ideas what's going wrong?</p>