[RESOLVED] CSS Issue Again :(
Ok, seems I forgetting the correct way to do this again.
I want to change the background color of a td cell upon the hover of it or the hover of the a tag.
Thanks
Code:
<tr style="WIDTH: 140px; HEIGHT: 12px">
<td class="menu-s" style="BORDER-RIGHT: #b22222 1px solid; BORDER-LEFT: #b22222 1px solid; WIDTH: 140px; COLOR: #b22222; HEIGHT: 12px"
vAlign="top" align="left" bgColor="#eeeeee" height="12"><a class="menu-s" href="#">Home</a>
</td>
</tr>
Code:
.menu-s td:hover, td a:hover {
text-decoration: underline;
color: #ffffff;
background-color: #b22222;
}
.menu-s A:link {
text-decoration: none;
color: #b22222;
}
.menu-s A:visited {
text-decoration: none;
color: #b22222;
}
.menu-s A:active {
text-decoration: none;
color: #ffffff;
background-color: #b22222;
}
.menu-s A:hover {
text-decoration: underline;
color: #ffffff;
background-color: #b22222;
}
Re: [RESOLVED] CSS Issue Again :(
You can have :hover on anything if you use an additional HTC-file and include it with IE-proprietary behavior property. Take a look at whatever:hover. It is a really helpful file :)
Btw, you can assign the same styles to different elements, ie.
Code:
.style a:active, .style a:link, .style:visited {
styles : here;
}
Much simpler than to copy the same rows multiple times :)