WebsiteBaker Support (2.8.x) > Templates, Menus & Design
show_menu2: valid XHTML and CSS selectable menus
yppds:
Hi!,
I know that the issue of show_menu2 has been extensively discussed in the forum, but I’m pretty desperate and need your help, after 5 hours of searching.
It is a multilingual site that has the following tree structure:
en
->home page
->News
->->news1
->->news2
->Pictures
->->Pictures 1
->->Pictures 2
de
->startseite
->Neues
->->neues1
->->neuses2
->Bilder
->->Bilder1
->->Bilder2
This site uses both show_menu2 and udm.
When the user is on the English page he will see only the English menu. When in deutch, he will see the deutch menu. To make it multilingual, I have followed – successfully - the tutorial that is posted on the wiki of WebsiteBaker and I have used the following to display the menu: show_menu2(0, SM2_ROOT+1, SM2_ALL, SM2_TRIM, false, false, ‘<ul class=”udm” id=”udm”>’);
Everything works fine. The problem starts when you click for instance on the Pictures1 link of the menu. The Pictures menu is becoming activated, but the News menu is becoming deactivated (it is shown, but you have to click on it, to show you the children of the menu). Also, assuming you click on News1, then the Pictures menu is becoming deactivated and you can only see the children if you click on it.
All I want is to make the menus always visible and activated, nomatter which route the user chooses.
Any help would really be appreciated.
kweitzel:
Haven't used that menu style myself, but from my understanding this is how it is supposed to work, actually ...
You can look for the breadcrumbs function to give you that page trail you would like to see (or as well the show_menu2 function).
cheers
Klaus
yppds:
Hi Klaus
Thanks for you help!
Well, after many trial and errors, I figure out one simple thing that might help you to guide me.
All I want is to make the menu always stay expandable. I don't want it to collapse.
The problem starts when you move from one category to the other. When you choose the Pictures category, it hides the News category (and all children) and shows only the contents of the Pictures menu category.
Could it be that the problem I have relates more with PHP code in include.php or legacy.php , than with how you type the show_menu2 function?
Looking forward for your help.
kweitzel:
you might be right three ... why don't you have a look at the source view of some redered pages ... then you will see if it is or not ... in general the menu function "resets" on every page loaded.
But also, these kind of menus are usually designed, that they do exactly that ... maybe it is not the right menu for you ... have you looked for explanations about the UDM Menu?
cheers
Klaus
brofield:
Seems to me that you want to use SM2_ALL instead of SM2_TRIM. Not sure that UDM is what you want either, since UDM is about create popup menus and you want to show the entire site structure all of the time.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version