When I code my Razor HTML like this:
@using (Html.BeginForm(new { ReturnUrl = ViewBag.ReturnUrl })) {
@Html.ValidationSummary()
}
I get the following which is just what I want:
<div class="validation-summary-valid" data-valmsg-summary="true">
<ul>
<li style="display:none"></li>
</ul>
</div>
However what I need for the form is the following:
<form class="form" data-href="/User/Account/Register" id="registerForm">
@Html.ValidationSummary()
</form>
With the above code I don't get the validation-summary-valid class. Can someone explain why this is or maybe suggest how I could code HTML.BeginForm so that I can get the form definition that I need.