WebsiteBaker Support (2.8.x) > Templates, Menus & Design
Desperate! Deadline :-( Show_menu2 - Multiple menu-trees in one menu
CodeALot:
Guys, I need help. But first, let's talk about WebsiteBaker and Show_menu2 :-D
I have a page-structure for two seperate sections of the site. Both seperate sections have their own template, because I assume I will have to call the menu in two different ways.
This is the page structure:
PRIVATE (menu-link to home)
home
contact
page3
BUSINESS (menu-link to home)
businesshome
businesscontact
businesspage3
Now, I want to call Show_menu2 in such a way that it will only show either the three options of the PRIVATE menu, or only the three options in the BUSINESS section of the menu.
I've tried this one:
--- Code: ---
<?php show_menu2(0, SM2_ROOT+1, SM2_ALL, SM2_ALL|SM2_CURRTREE, false, "\n</li>", false, false, false, '<ul id="header_menu" class="menu">'); ?>
--- End code ---
But somehow it seems that "CURRTREE" is ignored. With this call, ALL SIX of the options are shown in each menu.
Please....... HELP!
Ruud:
You could tell show_menu2() to start building his menu from a certain page.
Use:
show_menu2(0, 123, SM2_ALL, SM2_ALL,....);
where 123 is the pageid of the menu-link pages.
Both templates will have a different starting point (page_id), so that should do the trick.
I used this approach in multi language sites too.
R
CodeALot:
You're the best. Thanks Ruud! I managed to talk my way out of the deadline, so I gained some time to figure it out.
I did multilanguage menus before, but those weren;t Show_menu2 menus... And I needed a drop-down now too, so I got myself into trouble.
Thanks again Ruud, I'll let you know how it turned out!
CodeALot:
Ruud?
You rule. :)
Ruud:
I assume it worked? 8-)
R
Navigation
[0] Message Index
[#] Next page
Go to full version