title: Validate only ajax loaded partial view
body: <p>I have a form with some controls. There is a button on the form which loads a partial view. Inside the partial view, there are two required field textboxes along with a button. And when its clicked, I need to display error messages only for textboxes which are inside the partial view, but not for the fields in the actual form. And when I click form's submit button, all error messages must show up.</p>
  
  <p>After partial view is loaded, I am re-initializing the validation plugin as below.</p>
  
  <pre><code>$('#test').removeData("validator");
  $.validator.unobtrusive.parse('#test');
  </code></pre>
  
  <p>I tried using validation attribute described in below thread but its not working. Maybe it works for normally loaded views. </p>
  
  <p><a href="https://stackoverflow.com/questions/7340751/asp-net-mvc-validation-groups">ASP.NET MVC Validation Groups?</a></p>
  
  <p>However, I can validate individually by calling textbox1.valid() and textbox2.valid(). But I think I am missing standard way of doing it. Any help is appreciated.</p>