Common JavaScript events

Source: Internet
Author: User

Status

Event

Description

Mouse


Keyboard


Event

Onclick

This event is triggered when you click the mouse.

Ondblclick

This event is triggered when you double-click the mouse.

Onmousedown

Trigger this event when you press the mouse

Onmouseup

This event is triggered when you press the mouse and release the mouse.

Onmouseover

This event is triggered when you move the cursor over an object range.

Onmousemove

This event is triggered when you move the mouse.

Onmouseout

This event is triggered when the mouse leaves an object range.

Onkeypress

This event is triggered when a key on the keyboard is pressed and released

Onkeydown

This event is triggered when a button on the keyboard is pressed.

Onkeyup

This event is triggered when a key on the keyboard is pressed and released.

Page-related

Event

Onabort

This event is triggered when an image is interrupted during download.

Onload

This event is triggered when the page content is complete (that is, the page loading event)

Onresize

This event is triggered when the browser window size is changed

OnUnload

This event is triggered when the current page is changed

Status

Event

Description

Form-related

Event

Onblur

This event is triggered when the current element loses focus.

Onchange

This event is triggered when the current element loses focus and the element content changes.

Onfocus

This event is triggered when an element gets focus

Onreset

This event is triggered when the reset attribute in the form is activated.

Onsubmit

This event is triggered when a form is submitted.

Scroll subtitles


Event

Onbounce

Content in marquee is moved to the marquee display range

This event is triggered

Onfinish

This event is triggered when the marquee element completes the content to be displayed.

Onstart

This event is triggered when the marquee element begins to display content

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.