james438
08-24-2007, 04:30 PM
Hi, how do you get the link to be red when you hover over the link and green when you don't hover over the link whether you have visited the link or not?
I am using:
<style type="text/css">
a:link {
color:red;
}
a:hover {
color: #ffcc33;
}
a:visited {
color:purple;
}</style>
EDIT: Fixed. I looked through the forums and discovered that order is more important than I thought when dealing with CSS. The code should have looked like this:
<style type="text/css">
a:link {
color:red;
}
a:visited {
color:purple;
}
a:hover {
color: #ffcc33;
}</style>
I am using:
<style type="text/css">
a:link {
color:red;
}
a:hover {
color: #ffcc33;
}
a:visited {
color:purple;
}</style>
EDIT: Fixed. I looked through the forums and discovered that order is more important than I thought when dealing with CSS. The code should have looked like this:
<style type="text/css">
a:link {
color:red;
}
a:visited {
color:purple;
}
a:hover {
color: #ffcc33;
}</style>