<span class="stress bigsize">三年级</span>请问这样写有什么实际意义么?我写样式还要分开.stress、.bigsize这样写不是麻烦么?反正都是定义“三年级”,直接用一个来定义不是更省事?
Heson
2014-09-05
2 回答
是不是为了方便这么一种情况:
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>css</title>
<style type="text/css">
.colorred{color:red;}
.bigsize{font-size:18px;}
</style>
</head>
<body>
<p><span class="colorred bigsize">colorred colorgreen</span></p>
<p><span class="bigsize">bigsize</span></p>
<p><span class="colorred">colorred</span></p>
</body>
</html>举报
0/150
提交
取消