引入css

css (cascading style sheet)层叠样式表

1.行间样式

<div style="width:100px;height:100px;"></div>

2.页面级css(在head标签里面写)

<style type="text/css">
      div {
               width:100px;
               height:100px;
         }
</style>

3.外部css文件(在head标签里面写)

<link rel="stylesheet" type="text/css" herf="lesson.css">

 

          css选择器种类                               权重(256进制)

  !important                   Infinity

 1.行间样式                    1000

 2.id选择器                    100

 3.class类|属性                  10

 4.标签选择器                    1

 5.通配符(*)                   0

 6.父子选择器/派生选择器

 7.直接子元素选择器

 8.并列选择器

 9.分组选择器

 

 rgba(0, 0, 0, 0)  其中a为0表示完全透明

posted @ 2017-08-29 22:50  暮雨橙风  阅读(112)  评论(0编辑  收藏  举报