Link styles in CSS
Posted: Sat Aug 21, 2004 6:12 pm
Hello,
I've come upon this problem a couple of times, and being quite inexperienced in CSS I seek your advice.
The CSS I usually use for links in my pages if the following:
What this does is when the cursor is hovering over the mouse, the line disappears.
Now this set applies to my WHOLE page. Presume I'd want to have some different links in my page, for example I'd want the menu links not to be underlined, and instead become underlined when the mouse hovers over them.
How would I do that?
I suspect I could make classes but I'm not exactly sure how. I usually make classes like this:
Not sure how I have to do it in this case.
Also, if someone could give me a link to a CSS tutorial explaining the function of # : etc I would be thankful. I have looked at several tutorials but I've only actually seen these operators(?) in people's webpages.
Thank you very much.
I've come upon this problem a couple of times, and being quite inexperienced in CSS I seek your advice.
The CSS I usually use for links in my pages if the following:
Code: Select all
a:link {
text-decoration: underline;
color: black;
}
a:visited {
text-decoration: underline;
color: black;
}
a:hover {
text-decoration: none;
color: black;
}Now this set applies to my WHOLE page. Presume I'd want to have some different links in my page, for example I'd want the menu links not to be underlined, and instead become underlined when the mouse hovers over them.
How would I do that?
I suspect I could make classes but I'm not exactly sure how. I usually make classes like this:
Code: Select all
.class {
color: red;
}Also, if someone could give me a link to a CSS tutorial explaining the function of # : etc I would be thankful. I have looked at several tutorials but I've only actually seen these operators(?) in people's webpages.
Thank you very much.