我已经制作了一个我想用样式链接制作的网站。我不想为所有链接设置通用样式。我想为他们开设不同的课程。
我已经尝试在测试仪页面上执行此操作,但无法使其正常工作。这是代码:
<!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=UTF-8" />
<title>Untitled Document</title>
<style type="text/css">
test: link {
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: 1em;
color: #C00;
}
test: hover {
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: 1em;
color: #6F0;
}
test: active {
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: 1em;
color: #90F;
}
test: visited {
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: 1em;
color: #FF0;
}
.test {
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: 1em;
line-height: 1em;
color: #999;
}
</style>
</head>
<body>
Emily
<p>sdlkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjlsdkf
sdlkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjlsdkf
sdlkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjlsdkf
sdlkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjlsdkf
<span class="test"><a href="http://www.ehow.com/how_2080242_style-link-css.html">rose</a>
<a href="http://www.ehow.com/how_2080242_style-link-css.html"> daisy</a>
<a href="http://www.ehow.com/how_2080242_style-link-css.html">tulip</a>
<a href="http://www.ehow.com/how_2080242_style-link-css.html"> cactus</a> </span>
<p>ldkfjsldkfjlsdkfsdlkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjs ldkfjsldkfjlsdkfsdlkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsldkfjsld
</body>
</html>
有人可以告诉我我做错了什么。谢谢!