Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Adam Lewis 2 posts 72 karma points
    Oct 11, 2016 @ 14:07
    Adam Lewis
    0

    how does Umbraco MVC map to standard .net MVC directory structure?

    Hi,

    I'm fairly new to the world of Umbraco but I have already tried to search for the answer to my question without success. Can anyone point me to resources/tutorials explaining how and why Umbraco deviates from the standard Controllers/Models/Views directory structure.

    Thanks, Adam.

  • Alex Skrypnyk 5908 posts 22603 karma points MVP 4x admin c-trib
    Oct 11, 2016 @ 14:29
    Alex Skrypnyk
    0

    Hi Adam,

    Welcome to our forum!!!

    First or all read about controllers in Umbraco - https://our.umbraco.org/documentation/implementation/Controllers/

    There are few types, and each of them is great in some situation.

    Other great source for reading about controllers in Umbraco -

    https://github.com/kgiszewski/LearnUmbraco7/tree/master/Chapter%2006%20-%20Surface%2C%20WebAPI%20and%20RenderMVC%20Controllers

    And of course Umbraco TV - official Umbraco video course for new guys - http://umbraco.tv/

    Ask as many questions as you can.

    Thanks,

    Alex

  • Adam Lewis 2 posts 72 karma points
    Oct 11, 2016 @ 18:50
    Adam Lewis
    0

    Thanks Alex.

    I have looked at some of the documentation. I guess my question is why does a fresh MVC Umbraco installation not adopt the recognisable .NET MVC directory structure? Surely part of the advantage of the MVC approach is encourage a standard approach to separating function. I'm struggling to see how Umbraco tries to implement MVC in a similar way to .NET

    Any pointers to compare-and-contrast explanations gratefully received!

    Cheers, Adam.

  • Alex Skrypnyk 5908 posts 22603 karma points MVP 4x admin c-trib
    Oct 11, 2016 @ 20:50
    Alex Skrypnyk
    0

    Hi Adam,

    Do you mean why Umbraco hasn't Controllers folder by default?

    It's because if it will website project, controllers folder will not be compiled.

    If you will install Umbraco in web application folder - you will have controllers folder as in usual MVC web application.

    Thanks,

    Alex

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies