摘要: # 属性选择器是以 [ ] 作为标志的 方法一: [username] { /*把所有含有属性名是username的标签背景色改为红色*/ background-color: red; } 方法二: [username='jason'] { /*找到所有属性名是username并且属性值是jason 阅读全文
posted @ 2023-10-09 21:14 wellplayed 阅读(12) 评论(0) 推荐(0) 编辑
摘要: 1.后代选择器 /*后代选择器*/ div span { /*div后代所有的span*/ color: red; } 2.儿子选择器 /*儿子选择器*/ div>span { /*div下一级的后代中的span*/ color: red; } 3.毗邻选择器 /*毗邻选择器*/ div+span 阅读全文
posted @ 2023-10-09 21:05 wellplayed 阅读(12) 评论(0) 推荐(0) 编辑
摘要: 1.id选择器 /*id选择器*/ #d1 { /*找到id是d1的标签*/ color: green; } 2.类选择器 /*类选择器*/ .c1 { /*找到class值里包含c1的标签*/ color: red; } 3.元素(标签选择器) /*(元素)标签选择器*/ span { /*找到所 阅读全文
posted @ 2023-10-09 20:53 wellplayed 阅读(16) 评论(0) 推荐(0) 编辑
摘要: 1.无序列表 <ul type="square"> <li>第一项</li> <li>第二项</li> <li>第三项</li> <li>第四项</li> </ul> 2.有序列表 <ol type="1" start="5"> <li>111</li> <li>222</li> <li>333</ 阅读全文
posted @ 2023-10-09 18:50 wellplayed 阅读(7) 评论(0) 推荐(0) 编辑
摘要: 1.升序排序 select * from xxx order by 字段 2.降序排序 select * from xxx order by 字段 desc 阅读全文
posted @ 2023-10-09 16:43 wellplayed 阅读(28) 评论(0) 推荐(0) 编辑
摘要: # 查询学生表中所有数据 并且只取第一条数据SELECT * FROM student LIMIT 1 阅读全文
posted @ 2023-10-09 16:37 wellplayed 阅读(117) 评论(0) 推荐(0) 编辑