I. Type of event
The common main event types are described below:
OnClick an event handle that is invoked when a user taps an object. OnDblClick an event handle that is called when the user double-clicks an object. The onfocus element gets the focus. Exercise: The input box onblur element loses focus. scenario: For form validation, when a user leaves an input box, the Representative has already entered it and we can verify it. the contents of the onchange domain are changed. scenario: Typically used for form elements, which are triggered when the element content is changed. (three-level linkage) onkeydown a keyboard key is pressed. Application Scenario: When the user presses the ENTER key in the last input box, the form submits. onkeypress a keyboard key is pressed and released. onkeyup a keyboard key is released. OnLoad a page or an image to finish loading. onmousedown the mouse button is pressed. OnMouseMove Mouse is moved. onmouseout the mouse to move away from an element. onmouseover mouse moves over an element. OnMouseLeave mouse away from element onselect text is selected. OnSubmit confirm button is clicked.
Python Learning _day57_ front-end basics of JS5