Click to See Complete Forum and Search --> : Loss of link colors when using a style sheet


spiresgate
05-04-2008, 12:36 PM
When I use a style sheet for pages containing images used as links the link colors have disappeared. I can't see anything in the style sheet that could be causing this.

Here is the code for the external style sheet:

body {background-color: 330066 text: #000fff; link: #000000; vlink: #FFFFFF; alink: #FF0000}
h1 {font-size:2.4em; color:white;}
h2 {font-size:2.1em; color:white;}
h3 {font-size:1.8em; color:white;}
h4 {font-size:1.5em; color:white;}
h5 {font-size:1.2em; color:white;}
img {border:none}
h6 {font-size:0.9em; color:white; text-decoration:none;}

a:link {
color: #ffffff;
}
a:visited {
color: #ffd700;
}
a:hover {
color: #ff00ff;
background-color: #330066;
text-decoration: none;
}
a:active {
color: #00ff00;
}

body {background-color: #330066;}

li.badge {padding:10px;float:left; width: 80px; height: 150px; text-align:center;list-style-type: none; color:white;font-family:times; font-weight:600;}
table {
background-color:#306;
width:100%;
border:10px solid #306;
border-collapse:collapse;
}
table.gold {
background-color:#ffd700;
width:100%;
border:10px solid #ffd700;
border-collapse:collapse;
}
table.red {
background-color:red;
width:100%;
border:10px solid red;
border-collapse:collapse;
}

td {
background-color:#306;
border:0px solid black;
padding:5px;
}

input.text {
font-family: Arial;
font-size: 15pt;
font-weight: bold;
background-color: 330066;
border-color: 330066;
border-style: inset;
border-width: 0;
color:gold }

Can anyone explain?

ryanbutler
05-04-2008, 02:44 PM
Unless I'm misunderstanding, images that are behaving as links., in other words, nested inside links won't have link colors applied, which is what's supposed to happen.

Centauri
05-04-2008, 07:14 PM
If the images have no borders img {border:none}then where are the link colours going to be applied?

spiresgate
05-05-2008, 03:27 AM
Centauri has spotted it right! Works ok with that line removed.

Thank you both for your interest and troubling to take the time.