Installed Umbraco 7 but where are the controllers?
I've followed this http://our.umbraco.org/documentation/Installation to make a new umbraco 7 installation, and it works, but looking at at my project stucture in Visual Studio i can't find the controllers.
If you have installed a empty Umbraco solution, you will have to create your own controllers and controllers folder. Using Visual Studio, create a controllers folder in the root of your web site and then create a new controller. You should inherit the class from the SurfaceControllers class.
Especially the second part (from usercontrol to surfacecontroller) shows you a full example of the way to work with MVC.
FYI: Umbraco comes from the webforms world and likes to do it's own routing, just trying to wedge in default mvc routing is not going to work very well or at least it won't work together with Umbraco as a CMS.
Installed Umbraco 7 but where are the controllers?
I've followed this http://our.umbraco.org/documentation/Installation to make a new umbraco 7 installation, and it works, but looking at at my project stucture in Visual Studio i can't find the controllers.
Where are they?
Hi Jan,
If you have installed a empty Umbraco solution, you will have to create your own controllers and controllers folder. Using Visual Studio, create a controllers folder in the root of your web site and then create a new controller. You should inherit the class from the SurfaceControllers class.
Thanks, Dan.
Done that and i've also added routing to the Global.asax but it is still not working.
My controller is inheriting from RenderMvcController not Surfacecontroller.
Is there some routing setting in web.config that i have to update or anything else?
EDIT: When i call my controller i get a 404 from Umbraco. The controller is never called.
You might benefit from reading how to work with MVC in Umbraco as described in this blog post: http://umbraco.com/follow-us/blog-archive/2013/7/14/moving-from-webforms-to-mvc.aspx
Especially the second part (from usercontrol to surfacecontroller) shows you a full example of the way to work with MVC.
FYI: Umbraco comes from the webforms world and likes to do it's own routing, just trying to wedge in default mvc routing is not going to work very well or at least it won't work together with Umbraco as a CMS.
is working on a reply...