JavaScript Events

Event Event handler Applies to Occurs when
Abort  
onAbort  
images User aborts the loading of an image (for example by clicking a link or clicking the Stop button)
Blur  
onBlur  
windows and all form elements User removes input focus from window or form element
Change  
onChange  
text fields, textareas, select lists User changes value of element
Click  
onClick  
buttons, radio buttons, checkboxes, submit buttons, reset buttons, links User clicks form element or link
DragDrop  
onDragDrop  
windows User drops an object onto the browser window, such as dropping a file on the browser window
Error  
onError  
images, windows The loading of a document or image causes an error
Focus  
onFocus  
windows and all form elements User gives input focus to window or form element
KeyDown  
onKeyDown  
documents, images, links, text areas User depresses a key
KeyPress  
onKeyPress  
documents, images, links, text areas User presses or holds down a key
KeyUp  
onKeyUp  
documents, images, links, text areas User releases a key
Load  
onLoad  
document body User loads the page in the Navigator
MouseDown  
onMouseDown  
documents, buttons, links User depresses a mouse button
MouseMove  
onMouseMove  
nothing by default User moves the cursor
MouseOut  
onMouseOut  
areas, links User moves cursor out of a client-side image map or link
MouseOver  
onMouseOver  
links User moves cursor over a link
MouseUp  
onMouseUp  
documents, buttons, links User releases a mouse button
Move  
onMove  
windows User or script moves a window
Reset  
onReset  
forms User resets a form (clicks a Reset button)
Resize  
onResize  
windows User or script resizes a window
Select  
onSelect  
text fields, textareas User selects form element's input field
Submit  
onSubmit  
forms User submits a form
Unload  
onUnload
document body User exits the page