title: DataAnnotations driving client side validation issue
body: <p>I am trying to get what I think is a simple example of using DataAnnotations on a model to drive the client side validation as well.</p>
  
  <p>Here is my model...</p>
  
  <pre><code> public class Person
   {
    [Required(ErrorMessage = "First Name Required")]
    public string FirstName { get; set; }
    [Required(ErrorMessage = "Last Name Required")]
    public string LastName { get; set; }
   }
  </code></pre>
  
  <p>Here is my controller...</p>
  
  <pre><code> public class FriendsController : Controller
   {
    public ActionResult Create()
    {
     Person newFriend = new Person();
     return View(newFriend);
    }
  
    [HttpPost]
    public ActionResult Create(Person friendToCreate)
    {
     if (ModelState.IsValid)
     {
      // todo -- do something here
      return Redirect("/");
     }
  
     // Invalid - redisplay form with errors
     return View(friendToCreate);
    }
   }
  </code></pre>
  
  <p>and here is my view...</p>
  
  <pre><code>@model MvcApplication4.Models.Person
  &lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
      &lt;title&gt;@ViewBag.Title&lt;/title&gt;
      &lt;link href="@Url.Content("~/Content/Site.css")" rel="stylesheet" type="text/css" /&gt;
      &lt;script src="@Url.Content("~/Scripts/jquery-1.4.4.js")" type="text/javascript"&gt;&lt;/script&gt;
      &lt;script src="@Url.Content("~/Scripts/MicrosoftAjax.js")" type="text/javascript"&gt;&lt;/script&gt;
      &lt;script src="@Url.Content("~/Scripts/MicrosoftMvcValidation.js")" type="text/javascript"&gt;&lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
      &lt;h2&gt;
          Create&lt;/h2&gt;
      @{Html.EnableClientValidation();}
      @using (Html.BeginForm())
      { 
          &lt;fieldset&gt;
              &lt;p&gt;
                  @Html.LabelFor(m =&gt; m.FirstName)
                  @Html.TextBoxFor(m =&gt; m.FirstName)
                  @Html.ValidationMessageFor(m =&gt; m.FirstName)
              &lt;/p&gt;
              &lt;p&gt;
                  @Html.LabelFor(m =&gt; m.LastName)
                  @Html.TextBoxFor(m =&gt; m.LastName)
                  @Html.ValidationMessageFor(m =&gt; m.LastName)
              &lt;/p&gt;
              &lt;p&gt;
                  &lt;input type="submit" value="Create" /&gt;
              &lt;/p&gt;
          &lt;/fieldset&gt;
      }
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>The server side validation works just fine and the validation error messages appear as expected.  However, I am not getting the client side validation to work.  Is there something obvious that I am missing to make the client side validation appear?</p>