Adding a class to first child on drop down menu
Posted: Fri Jun 15, 2012 7:05 pm
I am porting a template to CMSMS and I am having an issue with getting the menu to display properly.
http://simpledesign.peppermgmt.com
I am using a copy of the minimal menu as follows:
I need to add a class of "arrow" on the first child only in the dropdown menu which adds an image. Everything I have tried hasnt worked. Can you point me in the right direction?
Thanks
Lisa
http://simpledesign.peppermgmt.com
I am using a copy of the minimal menu as follows:
Code: Select all
{if $count > 0}
<ul class="dd-menu">
{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}
{repeat string="<ul>" times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}
{repeat string="</li></ul>" times=$node->prevdepth-$node->depth}
</li>
{elseif $node->index > 0}</li>
{/if}
{if $node->current == true}
<li class="current-menu-item"><a href="{$node->url}" {if $node->target ne ""} target="{$node->target}"{/if}> {$node->menutext} </a>
{elseif $node->parent == true && $node->depth == 1 and $node->type != 'sectionheader' and $node->type != 'separator'}
<li class="activeparent"> <a href="{$node->url}" class="activeparent"{if $node->target ne ""} target="{$node->target}"{/if}> {$node->menutext} </a>
{elseif $node->type == 'sectionheader'}
<li class="sectionheader">{$node->menutext}
{elseif $node->type == 'separator'}
<li style="list-style-type: none;"> <hr class="separator" />
{else}
<li><a href="{$node->url}"{if $node->target ne ""} target="{$node->target}"{/if}> {$node->menutext} </a>
{/if}
{/foreach}
{repeat string="</li></ul>" times=$node->depth-1}</li>
</ul>
{/if}
Thanks
Lisa