WebsiteBaker Logo
  • *
  • Templates
  • Help
  • Add-ons
  • Download
  • Home
*
Welcome, Guest. Please login or register.

Login with username, password and session length
 

News


WebsiteBaker 2.13.6 is now available!


Will it continue with WB? It goes on! | Geht es mit WB weiter? Es geht weiter!
https://forum.websitebaker.org/index.php/topic,32340.msg226702.html#msg226702


The forum email address board@websitebaker.org is working again
https://forum.websitebaker.org/index.php/topic,32358.0.html


R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WB
https://forum.websitebaker.org/index.php/topic,32355.0.html


* Support WebsiteBaker

Your donations will help to:

  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!

You can donate by clicking on the button below.


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Menu siblings open
  • Print
Pages: [1]   Go Down

Author Topic: Menu siblings open  (Read 3697 times)

Offline noname8

  • Posts: 151
Menu siblings open
« on: December 28, 2009, 09:22:56 PM »
Hello!

I have problem that is really bugging me!

I need to make the sub menu's div / ul to be visible only when it's needed.
This is to make the ul around it to have special css.

How can I check without echoing the menu (now it does) that will this menu be visible :

Code: [Select]
<?php show_menu2(0, SM2_ROOT+2, SM2_CURR+1,&#39;&#39;,&#39;[li][a][menu_title]</a>&#39;,&#39;</li>&#39;,&#39;&#39;,&#39;&#39;); 


is_parent wont work because this menu shows current+1 also

fuller code:

Code: [Select]
if ($menu_needed) echo '<ul class="menu2">';
else echo '<ul class="hiddenclass">';

show_menu2(0, SM2_ROOT+2, SM2_CURR+1,'','[li][a][menu_title]</a>','</li>','','');
?>
</ul>



uuhhhhgghg FFFUFUFUFU..problem solved. Posting here always helps!  :mrgreen:
so the SM2_BUFFER was supposed to be without the '
Code: [Select]
show_menu2(0, SM2_ROOT+2, SM2_CURR+1,SM2_BUFFER,'[li][a][menu_title]</a>','</li>','','');


« Last Edit: December 29, 2009, 06:00:49 PM by noname8 »
Logged

Offline noname8

  • Posts: 151
Re: Menu check needed
« Reply #1 on: December 29, 2009, 05:59:36 PM »
If I have page with 2 level of sub pages
how can i make the sub pages also be visible when not seeing that sibling:

Code: [Select]
-hidden1
-hidden2
-hidden3(this one clicked to show menu2)
 -page a (this one clicked but..)
 -page b
 --page b1 (..these are still visible. Now I cannot make them visible)
 --page b2
 -page c

-hidden4



Code: [Select]
<?php show_menu2(0, SM2_ROOT+2, SM2_CURR+2, &#39;&#39; ,&#39;[li][a][menu_title]</a>&#39;,&#39;</li>&#39;,&#39;&#39;,&#39;&#39;); 
Logged

Offline noname8

  • Posts: 151
Re: Menu siblings open
« Reply #2 on: January 31, 2010, 08:03:27 PM »
Anyone ?
Logged

Swon

  • Guest
Re: Menu siblings open
« Reply #3 on: February 01, 2010, 12:59:34 PM »
you can see how to make a submenu, there is only showing if needed in my new template.
https://forum.WebsiteBaker.org/index.php/topic,16968.0.html
Logged

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Menu siblings open
 

  • SMF 2.0.19 | SMF © 2017, Simple Machines
  • XHTML
  • RSS
  • WAP2