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 /

mega menu - second level menu

Go to End



Community Member, 1 Post

6 March 2012 at 5:38am

Hi, I am developing a site using silver stripe. In that, I have to create a mega menu with two levels. When user hover on first level menu item, second level menu will be displayed for that item. In the second menu, I have different categories (skills, jobs, trainings) and these are not clickable and not children of first level menu item. second level menu items will be grouped under these categories. I did the following script to display second items but I don't know how to group second level items in to respective categories. Please check out this link for more information.

<% control Menu(1) %>
<div class="left{$LinkingMode}"></div>
<div class="$LinkingMode">
<div style="margin-top:5px;">
<a href="$Link" title="$Title.XML" class="$LinkingMode">$MenuTitle.XML</a>
<% if Children %>
<div id="$Title" class="sectionElement">
<% control Children %>
<li><a href="$Link" title="Go to the &quot;{$Title}&quot; page">$MenuTitle</a></li>
<% end_control %>
<% end_if %>
<div class="right{$LinkingMode}"></div>
<div class="menuspace">&nbsp;</div>
<% end_control %>