Home > Article > Web Front-end > Lesson03_02 Style Rule Selector_Basic Tutorial
就是HTML标签做为selector,这样在所有CSS应用的网页中,所有HTML标签都会按照所定义的语句来进行显示.
例如: p1 p2 p3 |
样式定义如下: |
网页中: text here |
样式定义如下: |
tag pair in the
tag pair is yellow, and the content in the tag pair from other places is not affected.
Note: Association selection is defined Rules take precedence over rules defined by a single selector.
Element name | Function |
---|---|
A:active | The state when a hyperlink is selected |
A:hover | The state when the cursor moves to the hyperlink |
A:link | The state without any action |
A:visited | Visited hyperlink status |
P:first-line | The first line of text in a paragraph |
P:first-letter | The first letter in the paragraph |