Customizing SMF > Graphics and Templates

multiple hyperlinks using .css

(1/1)

Les Mackenzie:
I have a webpage using a standard layout with a navigation bar along the top and quicklinks on the side.  I want the top navigation bar to be totally white save the a:hover.

But I want the Quick Links menu to support different colours within the same .css file?


--- Code: ---a:link    {color:#fff; background-color:transparent; font-size:7pt; font-weight:normal; text-decoration:none; font-family:verdana, arial, helvetica, sans-serif }
a:visited {color:#fff; background-color:transparent; font-size:7pt; font-weight:normal; text-decoration:none; font-family:verdana, arial, helvetica, sans-serif }
a:active  {color:#fff; background-color:transparent; font-size:7pt; font-weight:normal; text-decoration:none; font-family:verdana, arial, helvetica, sans-serif }
a:hover   {color:#FFFF00; background-color:transparent; font-size:7pt; font-weight:normal; text-decoration:none; font-family:verdana, arial, helvetica, sans-serif }


--- End code ---

Does anyone know if it's possible and howto if it is. 

Spaceman-Spiff:
make something like:
.navigation a:link
.navigation a:hover
etc

then for your navigation, in the table/td/div tag use class="navigation" and all links (a tags) inside will be using those css above

Les Mackenzie:
Thanks a lot Spiff  :P  I thought there'd be an easy way to do it  ;D

Seph|roth:
did that work? hmm always used this

a:link.someclass {... }
a:hover.someclass { ...}

[Unknown]:
I always prefer a.someclass:link... it just seems to make sense... element.class:psuedo-class..

-[Unknown]

Navigation

[0] Message Index

Go to full version