Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-24-2013, 05:28 PM   PM User | #1
TravisHD
New to the CF scene

 
Join Date: Jan 2013
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
TravisHD is an unknown quantity at this point
CSS Menu with "active" background color on a e-commerce system help

Hello all!

So we run an e-store at this link here (you'll see the menu I've created at the top).. http://store.theproductfarm.com

I have a CSS style for "active" to basically turn the background of the active page to the orange color (same as when you hover). However, I have this menu nested in the e-commerce systems "default.html" page so that it will show on ALL pages. However, this means if I set "home" to be the active one, it doesn't matter what page you're one, it will always have "home" highlighted.

How could I go about this in this situation? I know in a normal website structure I could choose to have contact.html for example to be "active" in the menu, but with this situation it's a little different.

Your help is greatly appreciated!
TravisHD is offline   Reply With Quote
Old 01-24-2013, 08:04 PM   PM User | #2
Excavator
Master Coder


 
Excavator's Avatar
 
Join Date: Dec 2006
Location: Alaska
Posts: 9,410
Thanks: 22
Thanked 1,765 Times in 1,749 Posts
Excavator has a spectacular aura aboutExcavator has a spectacular aura aboutExcavator has a spectacular aura about
TravisHD,
Look at this method that uses an id on the body of the document - http://nopeople.com/CSS%20tips/h_ul_...ges/index.html

You might find a .js solution that would work for you too.
__________________
Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad
Excavator is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 03:33 AM.


Advertisement
Log in to turn off these ads.