Events in JavaScript

We will discuss various events in JavaScript and associated triggers with example. Some practical examples we will develop through demo of these scripts.
Mouse EffectDescription
onMouseover & onMouseoutchange the background color of row or swap images on Mouseover
onMousedown & onMouseupEvents triggered when Mouse is clicked and when it is released.
onMousemoveWhen mouse is moved over the elements this event is triggered
onClickDisplay of Layer with onClick event of button
ondblClickManaging both Single and Double click events
Keyboard EventsDescription
onKeyPressWhile pressing a key the event to trigger
onKeyDownEvents to trigger whle a key is down
onKeyUpEvents to trigger on release of a key on keyboard

OnFocus Event

We can trigger events when we focus on any form component like textbox, radio button , checkbox etc. This can be achieved by shifting crusher to the component or by moving it by using tab , we can click on the component and keep the focus on it.

onunload event

We can display a message or trigger some script when visitor exit the page or closes the browser tab.

Subscribe to our mailing list

* indicates required
Subscribe to plus2net
Your Rating


Post Comment This is for short comments only. Use the forum for more discussions.

Subscribe to our mailing list

* indicates required
Subscribe to plus2net
HTML . MySQL. PHP. JavaScript. ASP. Photoshop. Articles. FORUM Contact us
©2000-2018 All rights reserved worldwide Privacy Policy Disclaimer