Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Customising the CMS

customising menus


Reply

2 Posts   1764 Views

Avatar
archiseek

12 June 2009 at 6:43am Community Member, 1 Post

I have the following site structure

main menu item 1
   sub menu item 1
   sub menu item 2
   sub menu item 3
   sub menu item 4

main menu item 2
   sub menu item 1
   sub menu item 2
   sub menu item 3
   sub menu item 4

main menu item 3

when in main menu item 1, the side nav shows the children pages
   sub menu item 1
   sub menu item 2
   sub menu item 3
   sub menu item 4
   
when in sub menu item 1, i want it to show its "sibling" pages ie
   sub menu item 2
   sub menu item 3
   sub menu item 4
   
   

Avatar
banal

12 June 2009 at 8:05am Community Member, 901 Posts

Use <% if LinkOrCurrent = current %> to see if the page is currently active.
Something like

<ul>
<% control Menu(1) %>
<% if LinkOrCurrent = current %>
<% else %>
<li><a href="$Link">$Title</a></li>
<% end_if %>
<% end_control>
</ul>