Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CSS link states 1

Status
Not open for further replies.

cbhead

Technical User
Jul 31, 2002
31
GB
Hi,
I have built an HTML page in Dreamweaver using CSS to define the link, active , visited and hover states of my page links.
At the moment active and hover are underlined. I also have a different colour for link and visited.

I need to know how to make visited links appear in a different colour but also appear underlined when the mouse moves over them (hover). However, I do not want the underlining to remain when I move the mouse away from the visited link.

This is probably a very simple problem to solve, if anyone knows the answer I would be grateful!

This is the current code in my stylesheet.

a:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 11px;
font-style: normal;
font-weight: bold;
color: #000099;
text-decoration: none;
}

a:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 11px;
font-weight: bold;
color: #970097;
text-decoration: underline;

}
a:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 11px;
font-weight: bold;
color: #970097;
text-decoration: none;

}
a:active {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 11px;
font-weight: bold;
color: #970097;
text-decoration: underline;
}

Thanks,
Cbhead.
 
So simple and it works!

Thanks Chris.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top