The visited pseudo-class
The visited pseudo-class specifies
styles for visited links. Typically, this
pseudo-class is used in conjunction with the
link,
hover
and active
pseudo-classes.
Syntax
cssa:visited {
}
Example
An unvisited link will be red, a visited link will be blue. If you hover over it with the mouse, it will turn green, and if you press the left mouse button and hold it, it will turn black (active state):
html<a href="#">link</a>cssa:link {
color: red;
}
a:visited {
color: blue;
}
a:hover {
color: green;
}
a:active {
color: black;
}
Результат: