View Full Version : css
ducktape
March 5th, 2002, 13:29
isnt there a way to make each link a different color.
like the links in the navbar 1 color and the links on the main section another color
PyschoPath
March 5th, 2002, 14:50
I don't think so.
Christopher
March 5th, 2002, 17:05
Yes.... Like this:
A.LINK { color : your main link color; }
A.LINK.navbar { color : your navbar link color; }
Then to make links in the navbar:
<a href="URL" class="navbar">URL</a>
To make links in the main section:
<a href="URL">URL</a>
You can also add a HOVER etc. feature to the "navbar" class, just like this:
A.LINK { color : your main link color; }
A.LINK.navbar { color : your navbar link color; }
A.HOVER.navbar { color : your hover color; }
Hope it helped...
ducktape
March 5th, 2002, 17:41
sure di thanx alot i knew there was a way just couldnt remember thanx alot
Christopher
March 5th, 2002, 20:02
Originally posted by michael p bennett
sure di thanx alot i knew there was a way just couldnt remember thanx alot
no problem! :D
meow
March 5th, 2002, 21:20
Only the syntax is wrong. There should be a colon before the psudo-class. Also, putting the pseudo-class last has better support since it's been around since CSS1.
a.navbar:hover
But this is also valid in CSS2
a:hover.navbar
Powered by vBulletin® Version 4.1.7 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.