How would I display a macro in my master template based upon a node or folder name?
For example, for main site use <umbraco:Macro Alias="getMainMenu" runat="server"></umbraco:Macro> but for /es/ (Spanish) portions, use <umbraco:Macro Alias="getMainMenu-Spanish" runat="server"></umbraco:Macro>
I would probably stick to just one macro in the template, and handle the logic for the Spanish menu in the XSLT.
If that logic is too complex, you could use the <xsl:include href="GetMainMenu-Es.xslt" /> and include the appropriate XSLT based on the active language.
Yeah, after I posted the message, I thought that a single macro with conditions inside would be an acceptable solution. Now, I'm just trying to figure out the XSLT to determine which "parent" node the page is under.
Conditional macro in master template
How would I display a macro in my master template based upon a node or folder name?
For example, for main site use <umbraco:Macro Alias="getMainMenu" runat="server"></umbraco:Macro> but for /es/ (Spanish) portions, use <umbraco:Macro Alias="getMainMenu-Spanish" runat="server"></umbraco:Macro>
Hi Connie,
I would probably stick to just one macro in the template, and handle the logic for the Spanish menu in the XSLT.
If that logic is too complex, you could use the <xsl:include href="GetMainMenu-Es.xslt" /> and include the appropriate XSLT based on the active language.
Grtz
Lennart
Yeah, after I posted the message, I thought that a single macro with conditions inside would be an acceptable solution. Now, I'm just trying to figure out the XSLT to determine which "parent" node the page is under.
is working on a reply...