尚硅谷web前端工程师学习笔记1000集20

<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<style type="text/css">
		
			/*
			 * 涉及到a的伪类一共有四个:
			 * 	:link
			 *  :visited
			 * 	:hover
			 * 	:active
			 * 而这四个选择器的优先级是一样的。
			 * link,visited要在hover、actIve上边,自身的顺序可以变
			 * hover一定要在active上面
			 */
			
			a:link{
				color: yellowgreen;
			}
			
			a:visited{
				color: red;
			}
			
			/*
			 * 鼠标移入
			 */
			a:hover{
				color: orange;
			}
			
			/*
			 * 正在点击
			 */
			a:active{
				color: cornflowerblue;
			}
			
			
			
			
			
		</style>
	</head>
	<body>
		
		<a href="http://www.baidu.com">访问过的链接</a>
		<br /><br />
		<a href="http://www.baidu123456.com">未访问过的链接</a>
		
	</body>
</html>
发布了37 篇原创文章 · 获赞 3 · 访问量 796

猜你喜欢

转载自blog.csdn.net/qq_38547320/article/details/104346331