How to change default view location scheme in ASP.NET MVC?

A simple solution would be to, in your Appication_Start get hold of the appropriate ViewEngine from the ViewEngines.Engines collection and update its ViewLocationFormats array and PartialViewLocationFormats. No hackery: it’s read/write by default. protected void Application_Start() { … // Allow looking up views in ~/Features/ directory var razorEngine = ViewEngines.Engines.OfType<RazorViewEngine>().First(); razorEngine.ViewLocationFormats = razorEngine.ViewLocationFormats.Concat(new string[] { “~/Features/{1}/{0}.cshtml” … Read more

ASP.NET MVC View Engine Comparison

ASP.NET MVC View Engines (Community Wiki) Since a comprehensive list does not appear to exist, let’s start one here on SO. This can be of great value to the ASP.NET MVC community if people add their experience (esp. anyone who contributed to one of these). Anything implementing IViewEngine (e.g. VirtualPathProviderViewEngine) is fair game here. Just … Read more