I want to have a submenu on my website, but only on pages who really have subpages. How can i check this?
-BTW, sorry for my bad Enlgish
Took you allredy a look at the show_menu2() function?
Stefek
Hi Gerben,
don't worry about your English, the mine isn't better :|
To answer your question, some details would be helpful:
- what WB version you use?
- what template you use / would like to use?
- what a menu-call is in this template: show_menu() - show_menu2() - a "hand-made" menu?
So the answer could be:
- take this or that parameter in your menu-call or
- change this or that code part in your template
- ...
You see: no "good" information == no "good" answers ;-)
Regards Bernd
Ok, thanx for comments.
@BerndJM:
Som extra Information:
WB 2.7
Own template
at the moment i use show_menu().
Soon as possible i will take a look at show_menu2(). Maybe is that a good way.
Gerben
Hi,
using SM2 is the easiest way to realize what you want:
For the main menu:
show_menu2(0, SM2_ROOT, ... other parameters depending on your needs)
for the submenu:
show_menu2(0, SM2_ROOT+1, ... other parameters depending on your needs)
So the submenu is only visible if you are on a page with subpages.
Regards Bernd
Little bit late, but it works.
Thanks!
Thanks Bernd :-)
This solved my problem also.