0

When i type something in a textfield before and now my browser has it in its "history".

Like if I typed in "idp" and when I go back to the same page and I then type just "i", it comes up with something like a dropdown selection and "idp" would be listed there.

If I selected "idp" from the selection, what javascript/jquery is triggered? I want to write additional codes to handle such an event

Here's a screenshot of what I'm talking about: http://i.imgur.com/tYgkgI9.png

Thanks a lot

Martin
  • 3,396
  • 5
  • 41
  • 67
mrjayviper
  • 149
  • 3
  • 12

1 Answers1

3

Chrome fires the input event when you choose something from the auto-fill list, which seems reasonable. In general, I'd expect a browser to fire input, change, or both when doing that. (change will typically only be fired when focus leaves the control, though.) Here's a test page that looks for input, change, and click.

T.J. Crowder
  • 1,031,962
  • 187
  • 1,923
  • 1,875