...

View Full Version : CSS an link/hover/visited



freddybee
12-15-2002, 12:25 PM
I do have a CSS file including :

a:link { text-decoration: none }
a:visited { text-decoration: none }
a:active { text-decoration: none }
a:hover { text-decoration: underline }
a:link, a:visited { color: #1F1D5A; font-weight : bold; }

.ABCD { color: #6C9EE8; background-color : #23407C;FONT-SIZE: 12px;}
.ABCD a:link, a:visited { color: #6C9EE8; font-weight : bold; }
.ABCD a:hover { color: #FEFEFE; }
.ABCD.bas { FONT-SIZE: 10px }

....
td.bgBlue { background-color: #6C9EE8 }



the line in the body :
<td class="BgBlue"><A href="detail.php?Record=1">TEST</A></td>

was supposed to have a link in color #1F1D5A but use #6C9EE8 instead ...

Any idea why ??

Thank you in advance

Kiwi
12-15-2002, 01:03 PM
The css cascade in tables is a bit funny (at least in practice, I don't know what the specs say). Anyway, the solution is to define a class. In your style sheet:


a.intable { color: #123456; }
a.intable:hover { text-decoration: underline; }
And in your document body:
<td class="BgBlue"><a href="detail.php?Record=1" class="intable">TEST</a></td>



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum