The MVC
is a framework, standard pattern for developing Web applications and MVC framework handled by three objects
Model, View and Controller.
Previously, MVC
3 contains only three templates i.e.
1.
Empty Template
2.
Intranet Application
Template
3.
Intranet Application
Template
Now, MVC 4 contains as following –
1. MVC 4 introduced a popular new feature that is
called Web API framework and its work over the HTTP services.
2. MVC 4 added and improves to default project templates.
3. MVC 4 introduced to empty project template.
4. MVC 4 introduced to new mobile project template.
5. MVC 4 is going to support and adding controller
to other project folders.
6. MVC 4 is going to support the Asynchronous
Controllers.
7. MVC 4 introduced to bundling and Magnification
concepts.
8. MVC 4 introduced to OAuth and OpenID login with
the help of DotNetOpenAuth library.
9. MVC 4 going to support to Windows Azure SDK 1.6.
Some Advance Features -
Full Support for Routes in MVC 4 –
routes.MapHttpRoute(
name: "DefaultApi",
routeTemplate:
"api/{controller}/{id}",
defaults: new
{ id = RouteParameter.Optional
}
);
Razor Enhancements - URL Resolution - Support for
~/ syntax
You can now write this -
<script
src="~/Scripts/site.js"></script>
Instead of writing this-
<script
src="@Url.Content("~/Scripts/site.js")"></script>
Conditional attribute rendering –
<div
@{if (myClass
!= null) { <text>class="@myClass"</text>
} }>Content</div>
References -More useful links for MVC 4