Click to See Complete Forum and Search --> : Image with link


orange_angel
07-02-2006, 03:38 AM
I'm redesigning my website using more CSS then before. I want the links to have a different color then the original settings (they should be pink not blue), the same with the borders around images with links.

This was the code that I used to have:
<html>
</head>
<body link="#ff51c1" vlink="#ddacc2">
<a href="143.html"><img src="143.jpg" width="150" height"200"></a>
</body>
</html>

Works very fine!
This, with CSS doesn't:

<html>
<head>
<STYLE TYPE="text/css">
<!--
A:link
{ color:#ff51c1; }
A:visited
{ color:#ddacc2; }
-->
</STYLE>
</head>
<body>
<a href="143.html"><img src="143.jpg" width="150" height"200"></a>
</body>
</html>

I've used IE when looking at the page, can someone help me?

Thanks!

GaryS
07-02-2006, 03:56 AM
Need a few extra lines in yor css:



a:link img
{ border: 1px solid #ff51c1; }
a:visited img
{ border: 1px solid #ddacc2; }

Wiz Creations
07-02-2006, 01:02 PM
This isn't part of the problem/solution, but the html comment tags aren't needed. You can take out the <!-- and -->