【代码笔记】Web-CSS-CSS 连接(link)

一,效果图。css

二,代码。html

复制代码

<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>CSS 连接(link)</title>
    <style>
    a:link {
        color: #ff0000;
        text-decoration: none;
        background-color: #b2ff99;
    }
    
    a:visited {
        color: #00ff00;
        text-decoration: none;
        background-color: #ffff85;
    }
    
    a:hover {
        color: #ff00ff;
        text-decoration: underline;
        background-color: #ff704d;
    }
    
    a:active {
        color: #0000ff;
        text-decoration: underline;
        background-color: #ff704d;
    }
    </style>
</head>

<body>
    <p><b><a href="/css" target="_blank">这是一个连接</a></b></p>
</body>

</html>

复制代码

 

参考资料:《菜鸟教程》htm