I've got an input field and I'm using the onblur event handler to call a method that does some validation when the input field loses focus.
Thats fine but if the user closes the window then onblur is calling that method to do the validation, which I dont want, if they close the window I would like the window to close without onblur calling that method.
How could I do this ?