How to design the children in navigator

For discussion and questions related to CMS Specific templates and stylesheets (CSS), and themes. or layout issues. This is not a place for generic "I don't know CSS issues"
Post Reply
petertak
New Member
New Member
Posts: 6
Joined: Fri Sep 23, 2016 10:02 am

How to design the children in navigator

Post by petertak »

Hi guys,
Is it possible to design the children of a navigator item? I already made a new Navigator design template and managed easily to style the main navigator items. But how about the childeren of an item? Is there a template for them?

I use CMSMS 2.2.5, navigator version = "1.0.8".

Thanx!
User avatar
DIGI3
Dev Team Member
Dev Team Member
Posts: 1609
Joined: Wed Feb 25, 2009 4:25 am
Location: Victoria, BC

Re: How to design the children in navigator

Post by DIGI3 »

You don't need separate templates for the children; Navigator templates are recursive. If you look at the default templates, you'll see that it cycles through the same sequence for parents and children.

Most of the sample templates add a class for the level, like .menudepth0, .menudepth1, etc., so you can target those in your stylesheet. You can add/calculate these yourself by using the $depth variable. For example, on my Foundation menu templates I usually have something like this in my Navigator templates:

Code: Select all

{if $depth==0}
  <ul class="menu accordion medium-dropdown">
{else}
  <ul class="menu">
{/if}
You can also just use css to target specific levels, like

Code: Select all

#mymenu ul ul
will just target levels below the first.
Not getting the answer you need? CMSMS support options
petertak
New Member
New Member
Posts: 6
Joined: Fri Sep 23, 2016 10:02 am

Re: How to design the children in navigator

Post by petertak »

Thanx for your reply and explanation. Exactly what i needed, it helped a lot. Thanx again.

Peter
Post Reply

Return to “Layout and Design (CSS & HTML)”