internet explorer - Methods from Javascript file will load in IE but not Chrome -
the webpage loading several different javascript files, of show correctly in "sources" tab of chrome's console, trying phone call methods 1 of pages results in console showing either "uncaught reference error: undefined not function" or "uncaught reference error: [name of function] not defined" depending on way function declared1. there's error in chrome console "uncaught syntaxerror: invalid left-hand side in assignment" coming page won't load, isn't nowadays in ie. error comes next function:
listofnumbers.prototype.reset = function () { = new listofnumbers; };
why can't access of functions on page?
1 difference in error messages that
variablename = function() {};
produces undefined not function
, while function functionname() {}
produces functionname not defined
.
the invalid left-hand side error explained in javascript function using “this = ” gives “invalid left-hand side in assignment”. ie give same error if seek run function, can see entering
var test = new listofnumbers(); test.reset();
in ie's console.
ie detects error when attempting run function, chrome observe on page load , prevent in javascript file running, though still show file under "sources". fixing invalid left-hand side should solve chrome problem.
javascript internet-explorer google-chrome
No comments:
Post a Comment