5 replies [Last post]
germanic42
Offline
newbie
Last seen: 18 years 44 weeks ago
Joined: 2003-12-02
Posts: 4
Points: 0

How do you add a color to the contents of a <sup> tag (from a css)?

Thanks,

Anonymous
Anonymous's picture
Guru

Re: Adding Color to the &lt;sup&gt; tag

sup {color: #f87;}

ian
ian's picture
Offline
Enthusiast
South Carolina
Last seen: 17 years 47 weeks ago
South Carolina
Timezone: GMT-5
Joined: 2004-11-08
Posts: 103
Points: 0

Adding Color to the &lt;sup&gt; tag

wouldn't you just style it like you would any other element?

<html>
<head>
<style>
<!--
.monkey {color: #999999;}
-->
</style>
</head>
<body>
<sup class=monkey>monkey</sup>is in gray!
</body>
</html>

or the way that Triumph just did it. . .

-clever quote at the bottom of my post-

germanic42
Offline
newbie
Last seen: 18 years 44 weeks ago
Joined: 2003-12-02
Posts: 4
Points: 0

Adding Color to the &lt;sup&gt; tag

I've been trying Triumph's way but it didn't work but now it dawns on me that the <sup> is a linking superscript.

How can I have a seperate color scheme for the sup links?

a:link {color: #000066;}
a:visited {color: #cc9966;}

Thanks,

ian
ian's picture
Offline
Enthusiast
South Carolina
Last seen: 17 years 47 weeks ago
South Carolina
Timezone: GMT-5
Joined: 2004-11-08
Posts: 103
Points: 0

Adding Color to the &lt;sup&gt; tag

wouldn't this:

sup a:link {color: #000066;}

sup a:visited {color: #cc9966;}

do it?

-clever quote at the bottom of my post-

germanic42
Offline
newbie
Last seen: 18 years 44 weeks ago
Joined: 2003-12-02
Posts: 4
Points: 0

Adding Color to the &lt;sup&gt; tag

Yes it would, thanks.