[jQuery] UNfocus() ?
[jQuery] UNfocus() ?
I am trying to emulate the :focus selector for IE, and I have succeeded in the initial aspect of that with the following:
$inputs.each(function(){
$(this).focus(function(){
$(this).addClass('focus');
});
});
However, once the focus leaves the field, the class remains applied. Surely I don't have to manually iterate $inputs and remove .focus if it's applied, and then add it to the current input, do I?
Thanks in advance for any help.