<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>伪类补充</title>
<style>
/*没有被点击时的样式*/
a:link {
color: green;
}
/*被访问 点击 过的链接*/
a:visited {
color: orange;
}
/*鼠标悬停时的样式*/
a:hover {
color: red;
}
/*鼠标按下 ,不要松开鼠标*/
a:active {
font-size: 36px;
}
/*:link伪类选择器应当放在其他伪类选择器的前面,
并且遵循LVHA的先后顺序,
即::link — :visited — :hover — :active。*/
/*鼠标按下 ,松开鼠标*/
a:focus {
font-size: 36px;
}
</style>
</head>
<body>
<a href="#">百度一下, 你就知道</a>
<a href="#">谷歌一下</a>
</body>
</html>
上述运行结果: