Several types of mouse trigger CSS events.
Description:
onMouseDown triggers when the mouse is pressed
onMouseOver triggers when the mouse passes over
onMouseUp triggers when the mouse is pressed and released
onMouseOut triggers when the mouse moves out
onMouseMove triggers when the mouse moves
CSS mouse response event
Mouse response event switches css when the mouse moves out
- onMouseDown triggers when the mouse is pressed
- onMouseOver triggers when the mouse passes
< li>onMouseUp Triggers when the mouse is pressed and released
- onMouseOut Triggers when the mouse moves out
- onMouseMove Triggers when the mouse moves
Change color style when the mouse passes over the table:
Control the color change of every other row in the table:
Simple application:
Add CSS file reference:
< link id="cssStyle" rel="stylesheet" type="text/css" href="../style.css" />