最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - IE and unspecified error and in IE8 object doesn't support method - Stack Overflow

programmeradmin1浏览0评论

I have a big (probably) javascript problem.

i have a long and plex script on the page based on mootools framework, in FF and other browser everything works fine, but in ie 6 and 7 i got "error:153 (sometimes 84) Unspecified error" and the strange thing is in IE8 that show me the error "Object doesn't support this property or method".

someone know the possible cause of the problem? o maybe someone know a list of IE's unsupported property or method?

I have a big (probably) javascript problem.

i have a long and plex script on the page based on mootools framework, in FF and other browser everything works fine, but in ie 6 and 7 i got "error:153 (sometimes 84) Unspecified error" and the strange thing is in IE8 that show me the error "Object doesn't support this property or method".

someone know the possible cause of the problem? o maybe someone know a list of IE's unsupported property or method?

Share Improve this question asked Jun 12, 2009 at 9:01 d3vilkissd3vilkiss 151 gold badge1 silver badge3 bronze badges 1
  • if in doubt, resorting to alerts to pinpoint the problem is not unreasonable at all – annakata Commented Jun 12, 2009 at 9:19
Add a ment  | 

5 Answers 5

Reset to default 2

In IE8 you can get the line number of the error, then right-click -> view source. IE8 has a proper source, which includes script lines, so you should quickly be able to find the source of your error.

If the script you're using isn't obfuscated or all on one line, you could use the JavaScript debugger in IE8 to pinpoint the object which is causing the error. Press F12 to open the Developer Tools, go to the Script tab, and click the "Start Debugging" option. If there's an error it may well break on the relevant line. If not you can set some breakpoints and step through the code.

You can also use IE8 developer tools http://blogs.msdn./ie/archive/2008/09/03/developer-tools-in-internet-explorer-8-beta-2.aspx to debug.

For other version I suggest you use Web developer tool bar which is similar to web developer tool bar for firefox.

Its near impossible to tell what the problem is with this information (at least for me).

For IE6/7 I suggest adding a few alerts to the javascript in intervals to find out exactly what line of code is causing your problem. If you know which object is causing the error, it is usually quite simple to find out what the exact problem is.

IE8 provides nice debugging tools, so that is a good place to start.

In my case the error was due to a $ mapping conflict.

Using jQuery instead of $ solved the issue.

发布评论

评论列表(0)

  1. 暂无评论