child entries not indenting with menu manager

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
swarfega
Forum Members
Forum Members
Posts: 174
Joined: Mon Sep 06, 2010 10:51 am

child entries not indenting with menu manager

Post by swarfega »

Ive changed my menu to use the examples from http://wiki.cmsmadesimple.org/index.php ... nu_Manager but Im finding that secondary level menu links arent indenting.

the menu code:

Code: Select all

{if $count > 0}
<ul class="menu_horiz">
{foreach from=$nodelist item=node}
{if $node->depth != $node->prevdepth}
{if $node->depth > $node->prevdepth}
<ul>
{elseif  $node->depth < $node->prevdepth}
</li></ul>
{/if}
{elseif $node->index > 0}
</li>
{/if}

{if $node->index == 0}
{assign var="icon" value="house"}
{elseif $node->haschildren == true }
{assign var="icon" value="folder"}
{elseif $node->haschildren == false }
{assign var="icon" value="page"}
{/if}
{if $node->current == true}
<li style="list-style-image: url('/cms/images/icons/{$icon}_go.png') ">
{else}
<li style="list-style-image: url('/cms/images/icons/{$icon}.png') ">
{/if}
{if $node->type == 'sectionheader'}
<span class="sectionheader{$node->depth}">{$node->menutext}</span>
{else}
<a href="{if $node->id == 15}/{else}{$node->url}{/if}"{if $node->target ne ""} target="{$node->target}"{/if}>{$node->menutext}</a>
{/if}
{/foreach}
	{repeat string="</li></ul>" times=$node->depth-1}		</li>
	</ul>
{/if}
You can see the result http://thriplow.org.uk/cms/news.pc
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: child entries not indenting with menu manager

Post by Dr.CSS »

I would use one of the default menu templates and CSS to style this instead of trying that menu template, it doesn't seem to give you any UL UL items, everything is in one UL...
swarfega
Forum Members
Forum Members
Posts: 174
Joined: Mon Sep 06, 2010 10:51 am

Re: child entries not indenting with menu manager

Post by swarfega »

ok ill give that a shot.
swarfega
Forum Members
Forum Members
Posts: 174
Joined: Mon Sep 06, 2010 10:51 am

Re: child entries not indenting with menu manager

Post by swarfega »

Managed to resolve this and still keep the above code.

Basically you need collapse=0 and use excludeprefix="" to list pages that you dont want listed.
Post Reply

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