Current page link highlighting ?
Posted: Thu Mar 18, 2010 3:31 am
Hi
What I'm trying to do is probably really simple, so I'll be having a stupid moment no doubt.
On my buttons I have a pink background when I hover over the button. This works fine. What i also need to do is for the button background to remain pink if I am on that page. The header file is called from an 'includes' folder BTW so I will not be able to assign a seperate class to it for each page I am on.
Here's my css.
Thanks in advance for any help.
What I'm trying to do is probably really simple, so I'll be having a stupid moment no doubt.
On my buttons I have a pink background when I hover over the button. This works fine. What i also need to do is for the button background to remain pink if I am on that page. The header file is called from an 'includes' folder BTW so I will not be able to assign a seperate class to it for each page I am on.
Here's my css.
Code: Select all
#menu a {
display: block;
width: 100px;
padding: 3px;
margin-right: 2pt;
background-color: #e6e6e6;
text-decoration: none;
text-align: center;
font-family: Georgia,"Times New Roman", Times, serif;
font-size: 10px;
font-weight: bold;
color: #4c4c4c;
border: none;
}
#menu a:hover, #menu a:active {
background-color: #ed1e79;
color: #fff;
}Thanks in advance for any help.