问题
My host provider only supports .NET 4. Is it possible to run MVC 5 and Web API 2 in .NET 4 machine?
回答1:
Short Answer: No, you need .NET 4.5
Only if you add the dependencies:
- Razor v3.0+
- ASP.NET WebPages v3.0+
回答2:
No, ASP.NET Web API 2 requires .NET 4.5: http://forums.asp.net/t/1937143.aspx?Is+ASP+NET+MVC+5+and+Web+API+2+0+supported+on+NET+4+0+and+IIS6+ (scroll at the very bottom)
来源:https://stackoverflow.com/questions/20411029/asp-net-mvc-5-and-web-api-2-net-requirement