Page 1 of 1

[solved] menu section header collapse

Posted: Fri Jan 08, 2010 1:09 pm
by konsument
Hey all,

Im trying around for hours to get this solved:

I have a menu like this:

-> Parent Item 1 (Section header)
---> Child Item 1 (content)
-----> ChildChild Item 1 (content)
-----> ChildChild Item 2 (content)
-----> ChildChild Item 3 (content)
---> Child Item 2 (content)
---> Child Item 3 (content)

-> Parent Item 2 (Section header)
---> Child Item 1 (content)

-> Parent Item 3 (Section header)
---> Child Item 1 (content)

Now I try to show only the Parent Items with first Child Items. All ChildChild Items should only show up if I click their parent item (Child Item). Something like "collapse all links from level 2".

I really need to get this solved. I allready played around with CGSimpleSmarty but cant get any solution.

Help would be highly appreciated!

best regards

 

Re: menu section header collapse

Posted: Fri Jan 08, 2010 3:51 pm
by konsument
ok. i finally got it  :D

probably not the very best solution but it works:

Code: Select all

{if $friendly_position|count_characters == "7"}{menu template="submenu.tpl" start_level="3" number_of_levels="5" collapse="0"}{else}{menu template="submenu.tpl" start_level="3" number_of_levels="4" collapse="0"}{/if}
thanks  ;D

Re: menu section header collapse

Posted: Sat Jan 09, 2010 4:18 pm
by konsument
Hello again,

unfortunately my solution does not work  :(

When I click my level 2 link all my level 3 links are shown - but I want to show only those links which are under the currently opened level 2 link.

Somebody has an idea?  ???

Re: menu section header collapse

Posted: Sat Jan 09, 2010 6:17 pm
by Dr.CSS
Sectioheader in most all of the default menu templates are not clickable, they are best used for drop down fly out type menus...

Most times the correct parameter to show only links related to the section/page that is open is collapse='1' this should make only the page your on and it's siblings links show in menu...

Re: menu section header collapse

Posted: Sun Jan 10, 2010 10:56 am
by konsument
Now I think I got it.

I just hide all not current opended level 3 menus with css.

I hope this is it now  :D

Re: menu section header collapse

Posted: Mon Mar 29, 2010 8:08 pm
by liquid
konsument wrote: I just hide all not current opended level 3 menus with css.
Can you share what you did? I'm running into the same issue. Thanks!