This project is read-only.

Project Description

This library is complete set of Validation Controls for ASP.NET MVC imported from ASP.NET WebForms in MVC Style, which are used in WebForms. It makes client side validation easier both for Developer and Designer with less code. It's developed in C#.

Feedback requested


On Web.Config

    <add tagPrefix="v" namespace="Classic.Mvc.Web.UI" assembly="Classic.Mvc.Web.UI"/>
    <add namespace="Classic.Mvc.Web.UI"/>

On Site.Master

<v:ValidatorScriptManager runat="server"></v:ValidatorScriptManager>

On View (eg. Index.aspx)

        props =>
				props.ShowSummary = true;
				props.ShowMessageBox = true;
				props.ValidationGroup = "test";

<input id="username" />
<%= Html.RequiredFieldValidator("reqVal_ username", "username",
        options =>
                options.Text = "*";
                options.ErrorMessage = "Invalid Username";
                options.SetFocusOnError = true;
                options.ValidationGroup = "test";
in submit handler of form (in javascript block or file) use following statements to check validity of controls and block submission of form
    return false;
"test" is validation group. You can use ValidationGroup to distinguish between forms

Last edited Oct 23, 2009 at 6:27 AM by guramrit, version 5