Friday, February 27, 2009
by
ASP.NET AJAX Team
|
Below is a table of the most common client side events in JavaScript. The Table is divided into three columns – the first lists the name of the event. The second contains a short description of the event, and the third lists all page objects, which support the given event.                                        Â
| Event Name |                Description | Supported by objects |
| Â onabort | The onabort event occurs when loading of an image is aborted. | image |
| onblur | The onblur event occurs when an object loses focus. | button, checkbox, fileUpload, layer, frame, password, radio, reset, submit, text, textarea, window |
| onchange | The onchange event occurs when the content of a field changes. | fileUpload, select, text, textarea |
| onclick | The onclick event occurs when an object gets clicked. | button, document, checkbox, link, radio, reset, submit |
| ondblclick | The ondblclick event occurs when an object gets double-clicked. | document, link |
| onerror | The onerror event is triggered when an error occurs loading a document or an image. | window, image |
| onfocus | The onfocus event occurs when an object gets focus. | button, checkbox, fileUpload, layer, frame, password, radio, reset, select, submit, text, textarea, window |
| onkeydown | The onkeydown event occurs when a keyboard key is pressed. Â | document, image, link, textarea |
| onkeypress | The onkeydown event occurs when a keyboard key is pressed or held down. | document, image, link, textarea |
| onkeyup | The onkeyup event occurs when a keyboard key is released. | document, image, link, textarea |
| onload | The onload event occurs immediately after a page or an image is loaded. | image, layer, window |
| onmousedown | The onmousedown event occurs when a mouse button is clicked. | button, document, link |
| onmousemove | The onmousemove event occurs when the mouse pointer is moved. Â | onmousemove is, by default, not an event of any object, because mouse movement happens very frequently. |
| onmouseout | The onmouseout event occurs when the mouse pointer moves away from a specified object. | layer, link |
| onmouseover | The onmouseover event occurs when the mouse pointer moves over a specified object. | layer, link |
| onmouseup | The onmouseup event occurs when a mouse button is released. | button, document, link |
| onreset | The onreset event occurs when the reset button in a form is clicked. | Form |
| onresize | The onresize event occurs when a window or frame is resized. | Window |
| onselect | The onselect event occurs when text is selected in a text or textarea field. | text, textarea |
| onsubmit | The onsubmit event occurs when the submit button in a form is clicked. | Form |
| onunload | The onunload event occurs when a user exits a page. Â | window |