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 »
  • Change active menu color when menu is developed using showmenu()
  • Print
Pages: [1]   Go Down

Author Topic: Change active menu color when menu is developed using showmenu()  (Read 6814 times)

Offline msherifam01

  • Posts: 9
Change active menu color when menu is developed using showmenu()
« on: December 28, 2010, 07:30:41 AM »
Hi,

I am new to WB. I have created a website. I have a horizontal menu which is developed using showmenu() function. How can i highlight the active menu?

For eg:
i have 3 pages: Home, About Us and Contact Us
Wen the web page is opened the current menu will be home. When About us is clicked it will display the content of about us page but it should also highloght the about us menu tab also. How can i do it if am using showmenu()?
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: Change active menu color when menu is developed using showmenu()
« Reply #1 on: December 28, 2010, 10:18:09 AM »
If you look at the sourcecode of your generated pages you should find the the classes that are added for the current menu-item.
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline msherifam01

  • Posts: 9
Re: Change active menu color when menu is developed using showmenu()
« Reply #2 on: December 28, 2010, 10:29:41 AM »
It comes in the div topNav. Inside that <ul> and <li>. But in source code it does not state that which is active.
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: Change active menu color when menu is developed using showmenu()
« Reply #3 on: December 28, 2010, 10:32:39 AM »
Can you tell us what the showmenu() call looks like in your template?

Can we have a look at the website?
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline msherifam01

  • Posts: 9
Re: Change active menu color when menu is developed using showmenu()
« Reply #4 on: December 28, 2010, 10:38:10 AM »
<?php show_menu(1, 0, 1, true, '<li>[a][menu_title][/a]','</li>','<ul>', '</ul>', '', ''); ?>
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: Change active menu color when menu is developed using showmenu()
« Reply #5 on: December 28, 2010, 11:02:02 AM »
WebsiteBaker has a pretty good help area online:
http://www.websitebaker2.org/en/help/designer-guide/multiple-menus.php#anker3

On this page you can see all parameters for the "old" show_menu() function.
There it shows the 10th parameter will be the class for the current menu.
In your call this is forced to "" (nothing).

By simply removing the last 2 parameters from your functioncall it should show " class="menu_current"" in the current active menupage.
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline msherifam01

  • Posts: 9
Re: Change active menu color when menu is developed using showmenu()
« Reply #6 on: December 28, 2010, 12:26:19 PM »
yes.. its working... Thanx..
Logged

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Change active menu color when menu is developed using showmenu()
 

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