[thelist] CSS, image border color and IE

Niklaus Haldimann n.haldimann at derbund.ch
Mon Nov 6 09:53:15 CST 2000


Hi gang.

I'm trying to add borders to images using CSS. I've had success with the
following approach in Netscape browsers:

<snip from style sheet>

a:link {color: #0066cc}
a:visited {color: #0066cc}
a:active {color: #000000}
a:hover {color: #000033}

a.pic:link {color: black}
a.pic:visited {color: black}
a.pic:active {color: black}
a.pic:hover {color: black}

</snip>

<snip from HTML source>
<a href="#" class="pic"><img src="pic.jpg" border="1"></a>
</snip>

All linked images are supposed to have a black border rather than a blue one.

It doesn't work in Internet Explorer. I guess I need to apply a class to
the images rather than to the anchors. But obviously I don't know how. Can
anybody help?

Thanks,
Niklaus.

--
http://eBund.ch http://eGames.ch
aktuell: http://www.eWahlen.ch




More information about the thelist mailing list