0

I have been facing an unexpected javascript errors recently while everything used to be fine before couple of weeks back. Not sure what is causing the issue.

here's the link of the page that causes unexpected errors in IE7/8 only, all other browsers works as expected.

Please Note: the disclaimer imortant-information.html should appear before the login page but it doesn't in ie7/8. Appreciate if any one could help... Thanks !!

important_info.html code loads script.html(has links for various javascript & plugins). Everything worked fine a week back but now it doesn't in ie7/8. No issues in firefox/chrome.

Error in IE7/8 -

    Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; MS-RTC LM 8; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C; .NET4.0E; InfoPath.3)
Timestamp: Mon, 16 Sep 2013 11:42:46 UTC


Message: Script error
Line: 0
Char: 0
Code: 0
URI: https://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js


Message: Script error
Line: 0
Char: 0
Code: 0
URI: https://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js
Dharmin
  • 3
  • 3
  • I just hit that URL with IE8, it redirected me differently than with FF. Have you been making some attempts to fix the issue? EDIT: the error report also shows you the file which is a problem, `hub.js`. Most of the time IE script errors like that are syntax-related, where a more modern JS engine would tolerate incorrect syntax and disregard extra commas on property lists, IE will error out. So if I were you I'd check that file for syntax and test again. – totallyNotLizards Sep 13 '13 at 07:46
  • not that I'm saying IE JS error reports can be trusted at all... – totallyNotLizards Sep 13 '13 at 07:49
  • hey thanks for the review but there was no errors since last week and I have three different server regions and on each it shows different errors related to hub.js & core.js and many others. As per my analysis it has something to do with DOM loading...Not sure – Dharmin Sep 13 '13 at 08:03
  • that's a possibility. I didn't realise you had different server regions... my best suggestion is to comment out all your scripts but the first one, and test. Uncomment each script one after the other until you get an error - then you'll find the source of the problem. It could be a race condition for the DOM loading, you can test that by wrapping your code in jQuery's document.ready function (basically put `$(function(){/*your code*/});` around your jQuery code) as this will cause jQuery to wait until the DOM has loaded before executing your code. Sorry but I can't think of anything else. – totallyNotLizards Sep 13 '13 at 08:35
  • actually if I hit script.html directly with firefox, I do get this error: `TypeError: siteConfig.getElementsByTagName is not a function https://www.bnymellonam.com/core/library/js/mam/search.js Line 1` – totallyNotLizards Sep 13 '13 at 08:38
  • 1
    There's this line in core.js (303): `$("#site-nav ul li#" + this[1] + "-nav").after($("#site-nav ul li#" + this - 1[1] + "-nav")).show()`. `this - 1[1]` seems odd... – Teemu Sep 13 '13 at 09:06
  • Everything seems fine now and the error was called "evil comma of doom"... Interesting to learn -> http://stackoverflow.com/questions/5139205/javascript-can-a-comma-occur-after-the-last-set-of-values-in-an-array – Dharmin Sep 16 '13 at 08:18
  • Hey though some errors resolved but final issue is with jquery file. I edited the question and one can see in Chrome console also the Uncaught Type Error etc etc. Any Idea what could be wrong ?? – Dharmin Sep 16 '13 at 11:46

0 Answers0