(Fixed)How to remove top level of hanging: minimal_menu
Posted: Tue Jun 26, 2012 1:17 pm
Dear All
I'm trying to set up a website that is look exectly the same as one that was written using simple HTML pages ( no php,aspx etc) The stylesheets etc were written by a colleague and i am just copying and pasting html into templates and content pages etc.
I'm very pleased how simple it has gone so far ( I tried using Drupal before and that was very complex) But i have a problem with the menu!
The existing site has 5 tabs at the top to select the 5 main sections so the menu on the left hand side just needs to display the subsections and just one level, so there will only be 2 levels across the whole site.
I'm using hanging: minimal_menu
The code on the Template is
{menu template="hanging : minimal_menu" number_of_levels="3"}
I think the code in the menu template is the same as orginally supplied
but its
{* CSS classes used in this template:
.currentpage - The active/current page
.bullet_sectionheader - To style section header
hr.separator - To style the ruler for the separator *}
{if $count > 0}
<ul class="clearfix">
{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><a href="{$node->url}" class="currentpage"{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}
I've had a look in the forum and somepeople have wanted to achieve a similar effect but not quite the same thing!
If anyone could give me a clue as to how to hide the top menu item of each section that would be great.
The site is at http://www.bri-advantage ... Membership
CMS Version 1.10.3
Php version 5.2.17
mysql (mysql) 5.1.63
Using litespeed web server
linux 2.6.18-408.el5.lve0.8.61.1 on x86_64
I have already managed to work out how to make the tab selected the correct one by using the name of the parent page so that subsections have the correct active tab, and the image is an Extra Page Attribute.
Kind Regards
Steve Whitcher
I'm trying to set up a website that is look exectly the same as one that was written using simple HTML pages ( no php,aspx etc) The stylesheets etc were written by a colleague and i am just copying and pasting html into templates and content pages etc.
I'm very pleased how simple it has gone so far ( I tried using Drupal before and that was very complex) But i have a problem with the menu!
The existing site has 5 tabs at the top to select the 5 main sections so the menu on the left hand side just needs to display the subsections and just one level, so there will only be 2 levels across the whole site.
I'm using hanging: minimal_menu
The code on the Template is
{menu template="hanging : minimal_menu" number_of_levels="3"}
I think the code in the menu template is the same as orginally supplied
but its
{* CSS classes used in this template:
.currentpage - The active/current page
.bullet_sectionheader - To style section header
hr.separator - To style the ruler for the separator *}
{if $count > 0}
<ul class="clearfix">
{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><a href="{$node->url}" class="currentpage"{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}
I've had a look in the forum and somepeople have wanted to achieve a similar effect but not quite the same thing!
If anyone could give me a clue as to how to hide the top menu item of each section that would be great.
The site is at http://www.bri-advantage ... Membership
CMS Version 1.10.3
Php version 5.2.17
mysql (mysql) 5.1.63
Using litespeed web server
linux 2.6.18-408.el5.lve0.8.61.1 on x86_64
I have already managed to work out how to make the tab selected the correct one by using the name of the parent page so that subsections have the correct active tab, and the image is an Extra Page Attribute.
Kind Regards
Steve Whitcher