PDA

View Full Version : css: link color & page style


jillhives
05-27-2005, 03:47 AM
I have a liked style sheet on html doc that has defined style selectors for link, hover, active & visited links. I want to make one link on the page a different color than the rest.
How do I do this?

Thanks.

domedia
06-01-2005, 03:38 PM
jill, just make a seperate class for that link
ie

a.other {text-decoration: none; font-weight: bold;}
a:link.other {color: #c00;}
a:visited.other {color: #c00;}
a:active.other {color: #c00;}
a:hover.other {color: #000;}
and then just use the class in your html: <a href="file.html" class="other">link</a>

Makes sense? :)