问题
In asp.net-mvc-3 - Improved model validation with unobtrusive JavaScript and jQuery support.
I think, unobtrusive-validation is already present in asp.net-mvc-2
Question : What exactly is improved in MVC3 pertaining to client validation?
回答1:
I think, unobtrusive-validation is already present in asp.net-mvc-2
Ah no, it wasn't.
Question : What exactly is improved in MVC3 pertaining to client validation?
The Ajax.* helpers are now using HTML5 data-* attributes which are interpreted by the jquery unobtrusive validation scripts. In ASP.NET MVC 2 the Ajax.* helpers were polluting the HTML with javascript calling to the absolute legacy Microsoft*.js
scripts.
来源:https://stackoverflow.com/questions/17336430/what-exactly-is-improved-in-mvc3-pertaining-to-validation