Definition and usage of pseudo-class selector e:hover:
Sets the style of the element when it hovers over it.
The e element can be selected by other selectors, such as the use of class selectors, ID selectors, type selectors, and so on.
Special Note: IE6 does not support this selector, but is able to support the A-element: hover, which is only supported by the type-selector selection of the A element: hover.
Syntax structure:
e:hover{Rules}
Browser support:
This selector is supported by IE browser.
Firefox supports this selector.
Google Chrome supports this selector.
This selector is supported by the Opera browser.
Instance code:
CSS Tutorials
- HTML area
- Div+css Zone
- JavaScript zone
- jquery Zone
Use the type selector to set the pre-access style of the hyperlink.
CSS Tutorials
- HTML area
- Div+css Zone
- JavaScript zone
- jquery Zone
Sets the style of the hyperlink on its mouse hover through the class selector and the ID selector. Not supported in IE6.
Code Farming Tutorial
The above code can change its background color when the mouse hovers over the Div, but also shows that: the hover pseudo-class is not only scoped to link a element.