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 »
  • Multi menus
  • Print
Pages: [1]   Go Down

Author Topic: Multi menus  (Read 4846 times)

Offline dazz

  • Posts: 11
Multi menus
« on: August 16, 2012, 12:56:00 PM »
Hi,

if I have multiple menus declared in info.php like
$menu[1]='Top';
$menu[2]='Engine';
$menu[3]='Chassis';

How can I print out the menu string.

for example I was hoping that something like

Code: [Select]

<?php echo $menu[2] ?>
<?php show_menu2(2, SM2_ROOT, SM2_ALL, SM2_ALL,false, "\n</li>", false, false, false, '<ul class="suckerfish">');?>

<?php echo $menu[3] ?>    
<?php show_menu2(3, SM2_ROOT, SM2_ALL, SM2_ALL,false, "\n</li>", false, false, false, '<ul class="suckerfish">');?>


would produce something like

Engine  

    Cast lite Piston Kits
    Forged Piston Kit
    Gasket sets
    Valve stem seal kits
    Individual Gaskets

Chassis

    Wheels
    Tanks
etc etc

any ideas, sure its not that hard....

« Last Edit: August 18, 2012, 10:16:28 AM by Argos »
Logged

Offline marmot

  • Posts: 1103
Re: Multi menus
« Reply #1 on: August 16, 2012, 09:19:28 PM »
Hi,

Quote from: dazz on August 16, 2012, 12:56:00 PM
How can I print out the menu string.
not sure what you are talking about, assuming you mean the menu name / title.
Quote
any ideas, sure its not that hard....
that's fine so you can do it by yourself  :-D or want to try something like this in your templates index.php:
Code: [Select]
<?php require_once("info.php"); echo $menu[2];?> and don't forget the semicolons.

regards
Logged

Offline dazz

  • Posts: 11
Re: Multi menus
« Reply #2 on: August 17, 2012, 05:49:32 AM »
thank marmot

Dazz
Logged

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

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