Overview of ASP. net mvc 2
ASP. net mvc 2 is a new version of ASP. net mvc, which adds many new features and improves the performance.
MVC 2 and MVC 1 can be installed and run on a single machine without mutual interference.
The latest version of MVC 2 is RC2.
MVC 2 RC2 for vs2008 is an independent installation package, and vs2010 RC has built-in MVC 2 RC2
At least. Net 3.5 is required.
Some default controller and view templates have changed.
New Features of ASP. net mvc 2 RC2
Better separation of concerns
Html. renderaction ()
Areas
Simple Verification Mechanism
Data annotations
Client Verification
Improved helper
Strong helpers
Templated helpers
Html. renderaction
Html. renderpartial ()
Direct rendering of the UI
Html. renderaction
Call the action in the Controller to render the UI
Areas
So that different functions in a project can be clearly differentiated
Arearegistration. registerallareas ();
Verify
Model Verification provider
Data annotation (default)
Enterprise Library
XML
...
Client Verification
Strong HTML helpers
Html. textboxfor ()
Html. textareafor ()
Html. validationmessagefor ()
....
Templated helpers
Helper Method Used for display
Html. Display ()
Html. displayfor ()
Html. displayformodel ()
Helper Method for editing
Html. Editor ()
Html. editorfor ()
Html. editorformodel ()
Other features
Including jquery 1.4.1
Controller and view corresponding T4 template changes
Jsonresult
Httppost, httpget...
Asynchronous Controller