JavaScript runtime error: Unable to get property 'opera' of undefined or null reference

一个人想着一个人 提交于 2019-12-25 04:56:13

问题


If I used jquery-1.9.1.min.js getting JavaScript runtime error: Unable to get property 'opera' of undefined or null reference from Jquery Isotope v1.5.19 javascript file.

If I use https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js JQuery. It is working properly and goes smooth. I all want to use latest of jQuery.

Any solution for this?


回答1:


If you want to continue using old jQuery APIs, you need to load the jquery-migrate plugin before the jquery.1.9.1.js script.

E.g.

<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="http://code.jquery.com/jquery-migrate-1.1.1.js"></script>

jquery-migrate download and read-me file

** Update:

Try to use Jquery Isotope v1.5.25. It was updated for Jquery 1.9 and doesn't have references to .browser plugin.

https://raw.github.com/desandro/isotope/master/jquery.isotope.js



来源:https://stackoverflow.com/questions/15816712/javascript-runtime-error-unable-to-get-property-opera-of-undefined-or-null-re

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!