Forum Moderators: not2easy
<style type="text/css">
A.LO:link {text-decoration: none; font-weight: normal; color: "#444141"}
A.LO:visited {text-decoration: none; font-weight: normal; color: "#444141"}
A.LO:active {text-decoration: none; font-weight: normal; color: #990033;}
A.LO:hover {text-decoration: none; font-weight: normal; color: #009bd9;}
</style>
Hope some one can help.
Thanks!
<style type="text/css">
<!--
.LN { font-family: Verdana, Arial, Helvetica; font-size: 12px; color: #FFFFFF}
.LN:hover {font-family: Verdana, Arial, Helvetica; font-size: 12px; color: #009bd9}
-->
</style>
<style type="text/css">
<!--
.LO { font-family: Verdana, Arial, Helvetica; font-size: 12px; color: #444141}
.LO:hover {font-family: Verdana, Arial, Helvetica; font-size: 12px; color: #009bd9}
-->
</style>
Thanks.
And what exactly do you want with your thingy..."But now the links are the same colour in all browsers." - Isn't that what you want? All browsers rendering the same way? Do you mean they ALL ignore the color you specified now? It's unclear.
"I need two links to be two different colours." - What do you mean by this? Do you just mean you want a color for link, and a different color for hovered? because the way it's worded there is very confusing.
Also, When styling sheets, if you have somethign like a{example: 5px;}, you don't need to specify a:hover{example:5px} unless it's different. It's a concept called inheritance, which occurs on virtually all elements styles.
Lastly, I recommend two things: one: ensure you have a proper DOCTYPE declaration on your pages, including test pages. Two: it's probably best to be using all lowercase for your CSS and HTML. While they are not case-sensitive... XHTML is case sensitive, and if ever or whenever you start coding for it, you should be accustomed to it. It also should make things easier for you considering you won't have to use capslock or shift anymore :).
Are you having trouble with your most recently posted code? It seems fine, if there's a problem with it, perhaps show us the broader sense of the page you are creating, still stripped down though of all unnecessary things, though.
[edited by: Xapti at 4:29 am (utc) on April 30, 2007]
The hover, active and visited are all working and are the right colours but 'Link' is not working.
I'm using this for my links: <a href="index.html" class="LN">
This is what I have in the CSS:
<style type="text/css">
<!--
.LN:Link {color: #FFFFFF}
.LN:visited {color: #FFFFFF}
.LN:hover {color: #009bd9}
.LN:active {color: #990033;}
-->
</style>
<style type="text/css">
<!--
.LO:Link {color: #444141}
.LO:visited {color: #444141}
.LO:hover {color: #009bd9}
.LO:active {color: #990033;}
-->
</style>
Thanks
I have come to the conclusion that 'Link' doesn’t work in FireFox.
hmmm, I think you have come to the wrong conclusion..
:link itself works fine in FF - there must be something else in your CSS that is overruling :link, perhaps some general a rules that are more specific by ID? test:
CSS:
body {background: #008;}.LN:link {color: #fff; /* white */}
.LN:visited {color: #fff; /* white */}
.LN:hover {color: #009bd9}
.LN:active {color: #990033;}.LO:link {color: #ff0; /* yellow */}
.LO:visited {color: #ff0; /* yellow */}
.LO:hover {color: #009bd9}
.LO:active {color: #990033;}HTML:
<a href="#no" class="LN">link class LN</a><br />
<a href="#no" class="LO">link class LO</a><br />
simple example works fine in FF, regardless of Doctype!
Must be something else in the CSS we can't see?
Suzy