I am trying to create a xslt script that just shows the products node. I can't seem to figure the variables in the script. DO you have any notes or documentation?
For instance the macro you use for the menu is like this:
Theres no official documentation on our navigation.xslt. What you're doing is allmost right.
The "rootPage" parameter is supposed to be an ID of the page to use as root of the menu. So you could just hardcode it to the Products page's ID.
Next is the "fromLevel" parameter. When using a "rootPage" or "useSelfAsRoot" the number in the "fromLevel" parameter should be relative to that node. So if I'm not much mistaken "fromLevel" should be 1.
"numberOfLevels" can be left out if you want all levels written. Or you can set it to a fixed number.
"showOnlyCurrentPath" is usually 1. That means that the menu will only "open up" childelements when you are on the parent element.
What NAV xslt are you using for the demo?
I am trying to create a xslt script that just shows the products node. I can't seem to figure the variables in the script. DO you have any notes or documentation?
For instance the macro you use for the menu is like this:
<umbraco:Macro fromLevel="3" navigationId="mainmenu" numberOfLevels="1" rootPage="" showOnlyCurrentPath="1" useSelfAsRoot="0" isSitemap="0" Alias="Navigation" runat="server"></umbraco:Macro>
But If I do something like this:
<umbraco:Macro fromLevel="4" navigationId="mainmenu" numberOfLevels="1" rootPage="Products" showOnlyCurrentPath="1" useSelfAsRoot="0" isSitemap="0" Alias="Navigation" runat="server"></umbraco:Macro>
I get nothing returned. Any ideas?
Hi Streety,
Theres no official documentation on our navigation.xslt. What you're doing is allmost right.
The "rootPage" parameter is supposed to be an ID of the page to use as root of the menu. So you could just hardcode it to the Products page's ID.
Next is the "fromLevel" parameter. When using a "rootPage" or "useSelfAsRoot" the number in the "fromLevel" parameter should be relative to that node. So if I'm not much mistaken "fromLevel" should be 1.
"numberOfLevels" can be left out if you want all levels written. Or you can set it to a fixed number.
"showOnlyCurrentPath" is usually 1. That means that the menu will only "open up" childelements when you are on the parent element.
Hope that helps a bit.
/Rune
Thanks Rune.
That got it
No problem. It's quite helpfull if you know how to use it.
/Rune
is working on a reply...