View Full Version : Link colour in style sheet won't work


luvhartz
12-31-2005, 02:28 PM
So i started using style sheets to make my life easier. I went and did the CSS for 4 stages for the links. the CSS is below. Only the A:link and A:active won't work in FireFox, it appears as default but the hover and visited all works fine =/ i don't know what i have done wrong here:

A:link { color: #FF66CC; text-decoration: none; cursor: crosshair; }
A:visited { color: #FF66CC; text-decoration: line-through; cursor: crosshair; height: 0; }
A:active { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }
A:hover { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }

Thanks for any help i appreciate it!

allie
12-31-2005, 05:12 PM
So i started using style sheets to make my life easier. I went and did the CSS for 4 stages for the links. the CSS is below. Only the A:link and A:active won't work in FireFox, it appears as default but the hover and visited all works fine =/ i don't know what i have done wrong here:

A:link { color: #FF66CC; text-decoration: none; cursor: crosshair; }
A:visited { color: #FF66CC; text-decoration: line-through; cursor: crosshair; height: 0; }
A:active { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }
A:hover { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }

Thanks for any help i appreciate it!

Try putting the attributes in this order and see what happens:

a:link { }
a:visited { }
a:hover { }
a:active { }

maztrin
12-31-2005, 05:15 PM
Try putting the attributes in this order and see what happens:

a:link { }
a:visited { }
a:hover { }
a:active { }

here is a little rhyme i like to use to remember that

LoVe HAte

...well its not really a rhyme :)

pb&j
12-31-2005, 05:37 PM
i put my own links css in the same order as your orignal post and they work ok.
that "height:0px" looks out of place.
can you provide a link to the page with this css coding on it? some other css coding may be a factor in your problem.

luvhartz
12-31-2005, 06:07 PM
its not currently up.. heres my style sheet:

<html>
<head>
<meta name="http://www.kerrysworld.net" content="in progress">
</head>
<STYLE TYPE="text/css">
<!--
A:link { color: #FF66CC; text-decoration: none; }
A:visited { color: #FF66CC; text-decoration: line-through; cursor: crosshair; height: 0; }
A:active { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }
A:hover { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }
A:img { border-style: none; }
div.header { color: #FFFFFF; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #FF66CC; }
div.links { color: #FF66CC; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #FFFFFF; }
body { cursor: crosshair; color: #CCFFCC; font-family: Verdana; background: #FFCCFF; scrollbar-3dlight-color: FFFFCC; scrollbar-arrow-color: FFFFFF; scrollbar-darkshadow-color: CCFFCC; scrollbar-face-color: FFFFCC; scrollbar-highlight-color: CCFFCC; scrollbar-shadow-color: 6BE2FE; scrollbar-track-color: CCFFCC }
img src { border: dashed 1px #09f }
input { color: #8298c3; font-size: 9pt; font-family: Verdana; line-height: 11pt; text-decoration: none; background-color: #ffff74; text-align: left; text-indent: 5px; border: dashed 1px #09f }
td.top { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
td.leftbar { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
td.middle { color: #FF66CC; font-size: 9pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #FFFFFF; }
td.rightbar { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
td.bottom { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
tr { color: #FFFFFF; font-size: 7pt; font-family: Verdana; line-height: 10px; background-color: transparent; border: solid 1px }
h5 { color: #ffff74; font-size: 11pt; font-family: monospace; font-weight: bold; line-height: 13pt; background-image: url("logos/naruto_bdaypics/hederback.jpg"); height: 11pt }
form { color: #09f; font-size: 9pt; line-height: 11pt; background-color: transparent }
-->

djou
12-31-2005, 07:31 PM
Remove the HTML comment tags (<!-- and -->)

pb&j
01-01-2006, 06:52 AM
is that the first part of your html page or is it a seperate css page?

if it is a seperate css page, then the top and bottom parts (red) should be delted.

height (yellow) is just odd being 0 in height.

# (lime green) should be added in for color codings.

a:img (blue) is probably not a working code. instead this should be used...
a img {styles;}


<html>
<head>
<meta name="http://www.kerrysworld.net" content="in progress">
</head>
<STYLE TYPE="text/css">
<!--
A:link { color: #FF66CC; text-decoration: none; }
A:visited { color: #FF66CC; text-decoration: line-through; cursor: crosshair; height: 0; }
A:active { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }
A:hover { color: #FF66CC; font-weight: bold; text-decoration: underline overline; }
A:img { border-style: none; }
div.header { color: #FFFFFF; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #FF66CC; }
div.links { color: #FF66CC; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #FFFFFF; }
body { cursor: crosshair; color: #CCFFCC; font-family: Verdana; background: #FFCCFF; scrollbar-3dlight-color:#FFFFCC; scrollbar-arrow-color: #FFFFFF; scrollbar-darkshadow-color: #CCFFCC; scrollbar-face-color: #FFFFCC; scrollbar-highlight-color: #CCFFCC; scrollbar-shadow-color: #6BE2FE; scrollbar-track-color: #CCFFCC }
img src { border: dashed 1px #09f }
input { color: #8298c3; font-size: 9pt; font-family: Verdana; line-height: 11pt; text-decoration: none; background-color: #ffff74; text-align: left; text-indent: 5px; border: dashed 1px #09f }
td.top { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
td.leftbar { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
td.middle { color: #FF66CC; font-size: 9pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #FFFFFF; }
td.rightbar { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
td.bottom { color: #000000; font-size: 8pt; font-family: Verdana; line-height: 10pt; text-decoration: none; background-color: #CCCCFF; }
tr { color: #FFFFFF; font-size: 7pt; font-family: Verdana; line-height: 10px; background-color: transparent; border: solid 1px }
h5 { color: #ffff74; font-size: 11pt; font-family: monospace; font-weight: bold; line-height: 13pt; background-image: url("logos/naruto_bdaypics/hederback.jpg"); height: 11pt }
form { color: #09f; font-size: 9pt; line-height: 11pt; background-color: transparent }
-->

luvhartz
01-01-2006, 11:01 AM
Awwwww thanks so much i did all your changes and it worked :D this is my firs time with stylesheets so thanks SOOOOOO much pb&j :D

pb&j
01-01-2006, 08:00 PM
cool. no prob.