View Full Version : Menu Bar Highlight

05-17-2010, 11:17 AM

When you create a menubar using HTML and CSS how do you get the menubar to highlight the section of the website that you are in? For instance on the www.sainsburys.co.uk website the section of the website that you are in appears in the menubar with a darker shade of orange.

The menu bar that I would like to implement this with is located here: www.devoteddomains.com.

Thanks in advance,

05-17-2010, 12:44 PM
Take a look at http://www.codingforums.com/showpost.php?p=605564&postcount=3

05-18-2010, 11:36 AM
Thanks, but my body tag is locked in a template I am using for the site so I can't make the body tag unique to each page, any other suggestions?

05-18-2010, 12:53 PM
Have you got any permission to edit the html of the menubar?

05-18-2010, 01:22 PM
Yes, I have put the menubar in a template myself.

05-18-2010, 01:51 PM
Then you could dynamically assign(using PHP) an attribute, say class="selected" on the list item/anchor based on the requested page in the url.