使用CSS设置所有访问过的链接的样式
要设置所有访问链接的样式,请使用CSS:visited选择器。
示例
您可以尝试运行以下代码来实现:visited选择器
<!DOCTYPE html>
<html>
<head>
<style>
a:link, a:visited {
background-color: white;
color: black;
border: 1px solid blue;
padding: 30px 30px;
text-align: center;
text-decoration: none;
display: inline-block;
}
a:hover, a:active {
background-color: red;
color: white;
}
</style>
</head>
<body>
<a href = "demo.html" target="_blank">Demo Link</a>
</body>
</html>热门推荐
10 祝女儿简短祝福语大全
11 大学新年祝福语简短创意
12 元旦适合的祝福语简短
13 朋友出远门祝福语简短
14 初六简短的祝福语
15 祝男孩生日祝福语简短
16 同事调离的祝福语简短
17 拜年红包的祝福语简短
18 妈妈生日祝福语简短励志