Copied to clipboard

Flag this post as spam?

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


  • K.Garrein 162 posts 626 karma points
    Mar 11, 2011 @ 11:37
    K.Garrein
    0

    Razor macro in the Developer section?

    Hey.

    I find lots of examples for inline Razor macro's like

    <umbraco:macro runat="server" language="razor">
    @using umbraco.MacroEngines
    @foreach( var Child in Model.Children ) {
     <p>@Child.Name</p>
    }
    </umbraco:macro>

    But how do I define a Razor macro in the Developer section of umbraco?

    Thank you.
    Regards.
    Kris.

  • K.Garrein 162 posts 626 karma points
    Mar 11, 2011 @ 11:46
    K.Garrein
    0

    Ok, I found it thanks to http://www.youtube.com/watch?v=NgnKy-VTimU&feature=youtu.be

    You add a cshtml file using "Scripting Files" in the Developer section.

    Regards.
    Kris

  • K.Garrein 162 posts 626 karma points
    Mar 11, 2011 @ 12:32
    K.Garrein
    0

    And may I say, this Razor stuff is AWESOME :-)

  • 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