Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Object doesn't support property or method 'attachEvent' InternetExplorer 11

If I press the form send button "Saada" in IE11, I will get an error:

Object doesn't support property or method 'attachEvent'

I have found that this is an IE11 problem, but the only solution I have found is to use my developer tools and set the browser to run in IE9 mode for example.

But I want everyone to use my website without using their developer tools.
Do you know some other solution I could try. Or maybe I have to import some other Jquery libraries?

Other browsers work fine, but this only happens in IE11

like image 245
student Avatar asked Feb 22 '15 15:02

student


1 Answers

The javascript method attachEvent was replaced with the method addEventListener in IE11.

JQuery 1.10.1 still uses this method in case of IE > 8. This will cause javascript compilation errors.

JQuery 1.10.2 seems to have solved this problem.

Hope this will help

like image 123
Babar Sajjad Avatar answered Nov 15 '22 11:11

Babar Sajjad