Skip to content Skip to sidebar Skip to footer

Jquery Focus Back To The Same Input Field On Error Not Working On All Browsers

I have a form with multiple fields which has both dynamically created fields and some pre defined fields. one of the field uses a jquery timepicker plugin courtesy of http://jonth

Solution 1:

It is an implementation bug in Firefox and IE, you can solve it using a timer. This is the new fiddle: http://jsfiddle.net/8cL42bcy/8/

I've added setTimeout(function() { $('#field').focus(); }, 50); at the end.

It will not affect Chrome in any way, because there is already focused.


Post a Comment for "Jquery Focus Back To The Same Input Field On Error Not Working On All Browsers"