摘要: :first-childp:first-child选择属于父元素的第一个子元素的每个 元素。 :last-child p:last-child 选择属于其父元素最后一个子元素每个 元素。 :before p:before 在每个 元素的内容之前插入内容。 :after p:after 在每个 元素的 阅读全文
posted @ 2022-05-22 20:57 呼长喜 阅读(18) 评论(0) 推荐(0) 编辑
摘要: :linka:link选择所有未被访问的链接。 :visited a:visited 选择所有已被访问的链接。 :active a:active 选择活动链接。 :hover a:hover 选择鼠标指针位于其上的链接。 <!DOCTYPE html><html lang="en"><head> < 阅读全文
posted @ 2022-05-22 20:38 呼长喜 阅读(17) 评论(0) 推荐(0) 编辑
摘要: /* E[att] 匹配所有具有att属性的E元素,不考虑它的值。(注意:E在此处可以省略。 比如“[cheacked]”。以下同。) p[title] { color:#f00; } E[att=val] 匹配所有att属性等于“val”的E元素 div[class=”error”] { colo 阅读全文
posted @ 2022-05-22 20:30 呼长喜 阅读(28) 评论(0) 推荐(0) 编辑