zoukankan      html  css  js  c++  java
  • 第17天:CSS引入、选择器优先级(中级)

    一、CSS 位置

      1、行内式  css  

       <div class="fr" style="color:red;">aa</div>

      2、 内嵌式样式

      <style>
        .one {
             200px;
        }
    </style>

      3、外链式

     <link rel=”stylesheet” href =”css/base.css” />

    二、Font 字体综合写

    Font: 字体加粗  字号/行高 字体;

      必须有字号和字体。

    Font-weight:bold;   700    

      S  del    删除线

      I   em   倾斜

      U   ins   下划线

          字体加粗  font-weight: 700;  

          让字体不加粗:  font-weight:normal;

          字体倾斜:  font-style:italic;  不用

          字体不倾斜: font-style:normal;

          不下划线 不删除线:  text-decoration: none;

          定位:  positionstatic;  静态定位   约等于标准流

          浮动的不浮动: float:none;      none  left  right

          定位的不定位:  position: static;    absolute  relative  fixed

    三、选择器的优先级

          标签  (1) < 类(10 ) id(100 ) 行内(1000)     

          网页稳定:

            Width height  最稳定

            其次 padding     

            最后才考虑margin

  • 相关阅读:
    nginx (待更新)
    根据 thread id 停止一个线程
    Redis 消息订阅
    faker smtp server
    DRF lazy Serializer
    python super
    django patch
    django patch 解决 ["'15428560000' value has an invalid format. It must be in YYYY-MM-DD HH:MM[:ss[.uuuuuu]][TZ] format."]
    自己的随笔
    CSS中文乱码解决方法
  • 原文地址:https://www.cnblogs.com/le220/p/7455935.html
Copyright © 2011-2022 走看看