WebsiteBaker Support (2.8.x) > Templates, Menus & Design
Inserting Headers in Menu
SnapDaddy:
Hi Bakers,
I would like to break up my menu list (showmenu2) with Text Headers. Is there a way to create these without having to use a bunch of multi menus?
Thanks
ruebenwurzel:
Hello,
make the text headers as parent pages and the other pages as subpages. Use the conditions of show_menu2 (look in readme.txt) to make the parent not as link and style them in your css.
Matthias
SnapDaddy:
Thanks Matthias,
I know there was a way...
The current menu I have displays from the first sub-page down. I would like to have just the first sub-pages be the header text and anything below them be links.
You wouldn't happen to have any examples of how I would use conditions to do this?
OK, got it figured out! Thanks again!
:-D
BerndJM:
Hi,
would you share your solution with the community?
Regards Bernd
SnapDaddy:
Here is what I did. I am using a mod version of the Multiflex-3 template. The Multiflex-3 template uses multi menus and <dl> for the side menus.
My top nav (showmenu2 (0)) bar opens with only root menus. The side nav (showmenu2 (1))opens from first sub-menu down with the fist sub-menu being the header text.
It is important to note that if you have sub-menu items, the first sub-menu will be non-linking text (header text).
Menu level <= 1 becomes the header text wrapped in an unordered list for styling.
index.php template file:
--- Code: ---<dl class="nav3-bullet">
<?php
show_menu2(1, SM2_ROOT+1, SM2_ALL, SM2_TRIM,'
[if(level<=1){<ul><li>[menu_title]}]
[if(level<=1){</li></ul>}]
[if(level>1){<dd>}]
[if(level==2){<dt>}]
[if(level>1){[a][menu_title]</a>}]
[if(level==2){</dt>}]
[if(level>1){</dd>}]
','','','');?>
</dl>
--- End code ---
Hope this helps!
Navigation
[0] Message Index
[#] Next page
Go to full version