tbosch / autofill-event

A polyfill to fire a change event when the browser auto fills form fields
MIT License
383 stars 53 forks source link

Error in IE8 #9

Closed joshbmarshall closed 10 years ago

joshbmarshall commented 10 years ago

IE8 can't use addEventListener, so it produces an error message

I fixed it locally using http://stackoverflow.com/questions/9769868/addeventlistener-not-working-in-ie8

dmatheron commented 10 years ago

+1 got the same issue in IE8

tbosch commented 10 years ago

This won't work in IE8, sorry, as it uses capturing event listeners for the blur event. Capturing event listeners (calling addEventListener with the last value set to true) are not supported in IE8 as far as I know (the normal attachEvent is just a bubbling event listener...)

tbosch commented 10 years ago

But maybe we don't need to listen for blur events in IE8, then it could work. Sorry, don't have IE8 here...

joshbmarshall commented 10 years ago

The work around I posted earlier is working well for me in production on a number of sites

Sent from my Android phone with K-9 Mail. Please excuse my brevity.

KimGressens commented 10 years ago

The workaround you posted isn't working for me.

To be complete : the workaround I tested was shimming the addEventListener call in IE8 . The result was that changes from the password manager were still not detected.

AdamQuadmon commented 10 years ago

I opened a PR for that

https://github.com/tbosch/autofill-event/pull/13

jca258 commented 10 years ago

This was solved with pull request #18

tbosch commented 10 years ago

Closing this as #18 is merged.