html css偽元素選擇器
阿新 • • 發佈:2018-12-26
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>無標題文件</title>
<style type="text/css">
/*訪問前*/
a:link {
background-color: #000000;
color: #3399FF;
font-size:18px;
}
/*訪問後*/
a:visited {
background-color: #CCFF00;
color: #6699FF;
font-size: 12px;
text-decoration:line-through;
}
/*懸停時*/
a:hover {
background-color: #CCFF00;
color: #6699FF;
font-size: 12px;
}
/*點選時*/
a:active {
background-color: #66CCFF;
color: #FFFFFF;
font-size: 16px;
}
/* L V H A為點選後恢復原狀態*/
</style>
</head>
<body>
<a href="http://www.sina.com.cn" target="_blank">hello workd </a>
</body>
</html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>無標題文件</title>
<style type="text/css">
/*訪問前*/
a:link {
background-color: #000000;
color: #3399FF;
font-size:18px;
}
/*訪問後*/
a:visited {
background-color: #CCFF00;
color: #6699FF;
font-size: 12px;
text-decoration:line-through;
}
/*懸停時*/
a:hover {
background-color: #CCFF00;
color: #6699FF;
font-size: 12px;
}
/*點選時*/
a:active {
background-color: #66CCFF;
color: #FFFFFF;
font-size: 16px;
}
/* L V H A為點選後恢復原狀態*/
</style>
</head>
<body>
<a href="http://www.sina.com.cn" target="_blank">hello workd </a>
</body>
</html>