views:

24

answers:

2

Is there any precedence to the javascript events that occur in a HTML page ? For example:

consider these two events onchange and onblur.

Change the text of a text box. The event onchange occurs only onblur of the text box. In this case which event will be processed first.

I hope I gave the understandable example.

A: 

I've just tested it on firefox and the onChange event occurs before the onBlur, but the onChange is fired only when you really change the input value. Anyway there is always a certain order in events occurance.

mck89
A: 

onChange, occurs first, if this is what you are asking

Starx