February 16th, 2012Enhancements to Default Project Templates:
· The template that is used to create new ASP.NET MVC 4 projects has been updated to create a more modern-looking website.
· In addition to cosmetic improvements, there’s improved functionality in the new template. The template employs a technique called adaptive rendering to look good in both desktop browsers and mobile browsers without any customization. To see adaptive rendering in action, you can use a mobile emulator or just try resizing the desktop browser window to be smaller. When the browser window gets small enough, the layout of the page will change.
· Another enhancement to the default project template is the use of JavaScript to provide a richer UI. The Login and Register links that are used in the template are examples of how to use the jQuery UI Dialog to present a rich login screen.
Mobile Project Template:
· If you’re starting a new project and want to create a site specifically for mobile and tablet browsers, you can use the new Mobile Application project template. This is based on jQuery Mobile, an open-source library for building touch-optimized UI. This template contains the same application structure as the Internet Application template (and the controller code is virtually identical), but it's styled using jQuery Mobile to look good and behave well on touch-based mobile devices.
Display Modes:
· The new Display Modes feature lets an application select views depending on the browser that's making the request. For example, if a desktop browser requests the Home page, the application might use the Views\Home\Index.cshtml template. If a mobile browser requests the Home page, the application might return the Views\Home\Index.mobile.cshtml template.
· Layouts and partials can also be overridden for particular browser types.
Recipes for Code Generation in Visual Studio:
· The new Recipes feature enables Visual Studio to generate solution-specific code based on packages that you can install using NuGet. The Recipes framework makes it easy for developers to write code-generation plugins, which you can also use to replace the built-in code generators for Add Area, Add Controller, and Add View. Because recipes are deployed as NuGet packages, they can easily be checked into source control and shared with all developers on the project automatically. They are also available on a per-solution basis.
Task Support for Asynchronous Controllers:
· You can now write asynchronous action methods as single methods that return an object of type Task or Task.
Azure SDK:
· ASP.NET MVC 4 Developer Preview supports the September 2011 1.5 release of the Windows Azure SDK.
October 8th, 2010New Features :
· NuPack Package Manager
· Improved New Project Dialog Box
· Simplified Way to Specify Strongly Typed Models in Razor Views
· Support for New ASP.NET Web Pages Helper Methods
· Additional Dependency Injection Support
· New Support for Unobtrusive jQuery-Based Ajax
· New Support for Unobtrusive jQuery Validation
· New Application-Wide Flags for Client Validation and Unobtrusive JavaScript
· New Support for Code that Runs Before Views Run
· New Support for the VBHTML Razor Syntax
· More Granular Control over ValidateInputAttribute
· Helpers Convert Underscores to Hyphens for HTML Attribute Names Specified Using Anonymous Objects
Bug Fixes:
· The default object template for the EditorFor and DisplayFor template helpers now supports the ordering specified in the DisplayAttribute.Order property. (In previous versions, the Order setting was not used.)
· Client validation now supports validation of overridden properties that have validation attributes applied.
· JsonValueProviderFactory is now registered by default.
July 28th, 2010· Razor View Engine
· Dynamic View and ViewModel Properties
· "Add View" Dialog Box Supports Multiple View Engines
· Service Location and Dependency Injection Support
· Global Filters
· New JsonValueProviderFactory Class
· Support for .NET Framework 4 Validation Attributes and IValidatableObject
· New IClientValidatable Interface
· Support for .NET Framework 4 Metadata Attributes
· New IMetadataAware Interface
· Permanent Redirect
New Action Result Types:
· HttpNotFoundResult Action
· HttpStatusCodeResult Action
March 12th, 2010· Fixed a bug that caused Internet Explorer versions 6, 7, and 8 (in compatibility mode) to hang when client validation is used in certain scenarios.
· Breaking Changes
February 5th, 2010· Every property for model objects that use IDataErrorInfo to perform validation is validated, regardless of whether a new value was set. (See Default validation system validates entire model earlier in this document.) In ASP.NET MVC 1.0, only properties that had new values set would be validated. In ASP.NET MVC 2, the Error property of IDataErrorInfo is called only if all the property validators were successful.
February 5th, 2010· IIS script mapping script is no longer available in the installer
· The IIS script mapping script is a command-line script that is used to configure script maps for IIS 6 and for IIS 7 in Classic mode. The script-mapping script is not needed if you use the Visual Studio Development Server or if you use IIS 7 in Integrated mode. The scripts are available as a separate unsupported download on the ASP.NET CodePlex site.
· The Html.Substitute helper method in MVC Futures is no longer available
· Due to changes in the rendering behavior of MVC view engines, the Html.Substitute helper method does not work and has been removed.
February 5th, 2010· The IValueProvider interface replaces all uses of IDictionary
· Every property or method argument that accepted IDictionary now accepts IValueProvider. This change affects only applications that include custom value providers or custom model binders.
Examples of properties and methods that are affected by this change include the following:
· The ValueProvider property of the ControllerBase and ModelBindingContext classes.
· The TryUpdateModel methods of the Controller class.
· New CSS classes were added in the Site.css file that are used to style validation messages.
February 5th, 2010· Helpers now return an MvcHtmlString object
· In order to take advantage of the new HTML-encoding expression syntax in ASP.NET 4, the return type for HTML helpers is now MvcHtmlString instead of a string. Note that if you use ASP.NET MVC 2 and the new helpers with ASP.NET 3.5, you will not be able to take advantage of the HTML-encoding syntax; the new syntax is available only when you run ASP.NET MVC 2 on ASP.NET 4.
· JsonResult now responds only to HTTP POST requests
· In order to mitigate JSON hijacking attacks that have the potential for information disclosure, by default, the JsonResult class now responds only to HTTP POST requests. Ajax GET calls to action methods that return a JsonResult object should be changed to use POST instead. If necessary, you can override this behavior by setting the new JsonRequestBehavior property of JsonResult. For more information about the potential exploit, see the blog post JSON Hijacking on Phil Haack’s blog.
· Model and ModelType property setters on ModelBindingContext are obsolete
· A new settable ModelMetadata property has been added to the ModelBindingContext class. The new property encapsulates both the Model and the ModelType properties. Although the Model and ModelType properties are obsolete, for backward compatibility the property getters still work; they delegate to the ModelMetadata property to retrieve the value.
· Changes in ASP.NET MVC 2 Preview 1
February 5th, 2010· Changes to the DefaultControllerFactory class break custom controller factories that derive from it
· The DefaultControllerFactory class was fixed by removing the RequestContext property. In place of this property, the request context instance is passed to the protected virtual GetControllerInstance and GetControllerType methods. This change affects custom controller factories that derive from DefaultControllerFactory.
· Custom controller factories are often used to provide dependency injection for ASP.NET MVC applications. To update the custom controller factories to support ASP.NET MVC 2, change the method signature or signatures to match the new signatures, and use the request context parameter instead of the property.
· “Area” is a now a reserved route-value key
· The string “area” in Route values now has special meaning in ASP.NET MVC, in the same way that “controller” and “action” do. One implication is that if HTML helpers are supplied with a route-value dictionary containing “area”, the helpers will no longer append “area” in the query string.
· If you are using the Areas feature, make sure to not use {area} as part of your route URL.