博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
第17天:CSS引入、选择器优先级(中级)
阅读量:5744 次
发布时间:2019-06-18

本文共 611 字,大约阅读时间需要 2 分钟。

一、CSS 位置

  1、行内式  css  

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

  2、 内嵌式样式

  <style>

    .one {
        width: 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

转载地址:http://xrizx.baihongyu.com/

你可能感兴趣的文章
论文笔记:Multi-Agent Actor-Critic for Mixed Cooperative-Competitive Environments
查看>>
SQL中EXPLAIN命令详解
查看>>
oracle之 数据泵dump文件存放nfs报ORA-27054
查看>>
ASP.NET 跨域请求之jQuery的ajax jsonp的使用解惑 (转载)
查看>>
5分钟了解Mockito
查看>>
设置VMware随系统开机自动启动并引导虚拟机操作系统
查看>>
影响股市的主要因素有哪些
查看>>
电脑技巧 如何通过声音 音乐找到歌曲
查看>>
SpringCloud学习笔记(3)——Hystrix
查看>>
centos系统安装rar解压工具unar
查看>>
rsync 自动创建目录的坑点
查看>>
多线程之互斥锁(By C++)
查看>>
Oracle创建表空间及用户
查看>>
ZTree 获取选中的项
查看>>
asp.net MVC AngularJS
查看>>
python初级 2 字符串格式化
查看>>
React Native库版本升级与降级
查看>>
SuSE Linux Supervisor的安装与使用案例
查看>>
LeetCode Binary Tree Level Order Traversal II
查看>>
约束5:外键约束
查看>>