码迷,mamicode.com
首页 > Web开发 > 详细

01.css选择器-->类选择器

时间:2017-10-10 20:44:46      阅读:167      评论:0      收藏:0      [点我收藏+]

标签:col   highlight   css选择器   set   yellow   lan   选择器   logs   oct   

<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<style>
	#div1 .text{
		color: red;
	}
	#div2 .text{
		color: yellow;
	}
</style>
<title>类选择器</title>
</head>
<body>
	<div id="div1">
		<p class="text">这是黄色</p>
	</div>
	<p class="q"></p>
	<p class="w"></p>
	<p class="e"></p>
	<p class="r"></p>
	<div id="div2">
		<p class="text">这是红色</p>
	</div>
</body>
</html>

  

01.css选择器-->类选择器

标签:col   highlight   css选择器   set   yellow   lan   选择器   logs   oct   

原文地址:http://www.cnblogs.com/ronghtp/p/7647318.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!