[lug] OT: CSS2, mixing pseudo-class with class

Sexton, George gsexton at mhsoftware.com
Fri Sep 27 10:06:08 MDT 2002


A.foot:visited
A.link:LINK

-----Original Message-----
From: lug-admin at lug.boulder.co.us [mailto:lug-admin at lug.boulder.co.us]On
Behalf Of Rob Judd
Sent: 27 September, 2002 9:13 AM
To: BLUG
Subject: Re: [lug] OT: CSS2, mixing pseudo-class with class


> I'm trying to figure out if I can modify my CSS2 stylesheet. Currently
> it has A:visited and A:link to adjust colors, but I wanted to have a
> second class of <A> "anchor" tags, within a list, and I wanted this to
> be a new class, e.g., class "foo", with different color attributes. Is
> there a way to have both a general CSS2:
> A:visited {
> ...
> }
> A:link {
> ...
> }
>
> ...and also a specific:
> A:visited.foo {
> ...
> }
> A:link.foo {
> ...
> }
>
> So far I haven't found a valid way to mix :link and :visited pseudo-tags
> with my own class name. Perhaps it isn't even possible.

I believe that the correct syntax to have a class foo with different
attributes is:

A.foo:visited {
...
}

A.foo:link {
...
}

(this is from the O'Reilly CSS book, p157).

Cheers, Rob

_______________________________________________
Web Page:  http://lug.boulder.co.us
Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
Join us on IRC: lug.boulder.co.us port=6667 channel=#colug




More information about the LUG mailing list