Basic CSS

Soldato
Joined
7 Apr 2004
Posts
4,212
Hey,

Can someone tell me how to change the color and font (remove the underline) of a link using CSS if possible, I dont want to apply it to the whole page, so can I use the <style> tags? I would also like to make the mouseover and vistied/active states so they always look the same.

Thanks a lot.
 
a:link

a:visited

a:active

a:hover


are the selectors you want

Add values to these depending on what state you want them in.

E.g. anchor link that has been visited

Code:
a:visited {color: #0000FF; text-decoration: none;}

All four selectors should be within the CSS.

I dont want to apply it to the whole page, so can I use the <style> tags?

:confused:

The <style> tags are for inline stylesheets. If you only want a certain text to have seperate styles, give that particular link a class.
 
Back
Top Bottom