1)无序列表
基本语法
功能
-  标签定义无序列表。
 - 标签一起使用,创建无序列表。
列表样式类型
1、ul标签样式ul{list-style-type:none;margin:0px auto;padding:0px;background-color:#000000;color:#ffffff;display:flex;justify-content:center;}list-style-type:none; 设置列表样式类型无margin:0px auto; 设置上下外延边距为0,左右外延边距距中padding:0px; 设置内部边距为0background-color:#000000; 设置背景色为黑色color:#ffffff; 设置文字颜色为白色display:flex; 设置ul标签为弹性容器justify-content:center; 设置容器内容距中2、li标签样式li{width:200px;line-height:50px;text-align:center;background-size:100% 100%;}width:200px; 设置宽度为200像素line-height:50px; 设置行高为50像素text-align:center; 设置文本距中background-size:100% 100%; 设置背景图大小长100%、高100%显示3、:nth-of-type()ul li:nth-of-type(6){background-image:url("http://www.yyfun001.com/res/htmlclassics/full/images/136.jpg");}ul li:nth-of-type(6) 选择ul下第6个li元素background-image:url("http://www.yyfun001.com/res/htmlclassics/full/images/136.jpg"); 设置背景图4、:not(id)ul li:not(#first){background-color:green;}ul li:not(#first) 选择ul下除id为first的li标签以外的元素background-color:green; 设置背景颜色为绿色
2)有序列表
有序列表也是一列项目,列表项目使用数字进行标记。
有序列表始于 
将
-  标签与
 
