javascript - JS assets in a subdomain wont load on ff & ie but chrome is all good -
we building saas product , have purchased bootstrap dashboard, js/css assets loaded though sobdomain via our cdn.
works on chrome on ie , ff components not load properly, on ff following errors: typeerror: can't access dead object referenceerror: event not defined
a link non working example below (we don't want give access our working dashboard commercial reasons) can see error when click on "dropdown" menu item. far can tell, assets loading correctly.
http://hunchbuzz.com/acme/index.html
any appreciated.
well, take bugs 1 one. did turn on javascript debugger when tested page in ie? in f12 developer tools, select script , start debugging.
first there couple of errors in jquery.sparkline.min.js
ignored moment. tried clicking 'dropdown' link , got error:
script438: object doesn't support property or method 'preventdefault' custom.js, line 3 character 1193
the highlighted code (reformatted readability):
$('.dropmenu').click( function(){ event.preventdefault(); // ... });
do see problem? event
? code should be:
$('.dropmenu').click( function( event ){ event.preventdefault(); // ... });
the fact worked in browser @ due global event
variable browsers create compatibility old code.
now sparkline problems. see hitting 2 errors in jquery.sparkline.min.js
, minimized code problem isn't jumping out @ me way other 1 did.
when you're debugging, lot load non-minified versions of jquery.sparkline.js
, custom.js
, jquery, etc. you'll have readable code @ in debugger, should make easier spot these problems.
Comments
Post a Comment