EditorTemplates (1)


Adding client-side validation to custom Editor Templates in MVC

When an editor template is overridden with custom one you lose automatic scaffolding of client-side validation which uses data annotation rules. In such a case they should be added manually to your templates. In the beginning of HTML form you should add  @Html.ValidationSummary(true). The parameter excludePropertyErrors = true because I don’t want to mix up error for […]