
选择器用来找到需要添加样式的位置,常用选择器有,标签选择器,类选择器,ID选择器

background-attachment的值若是scroll,背景随滚动条滚动,是fixed不随滚动条滚动

将CSS样式代码单独拆分到一个文件中,通过link的方式引入会HTML代码中,是网页的HTML代码与CSS代码彻底分离

通过link将index.css的css文件引入到first.html中
CSS三种样式加载方式
行内样式>内部样式>外部链接方式
常用的文本样式,对文本进行修饰

text-align的属性值justify的作用实现文本两端对齐


text-indent 首行缩进 属性值可以是length这样的长度 也可以是2em这样的字符倍数 2em代表首行缩进2个字符的长度

网友评论