Version: (using KDE KDE 3.5.0) Installed from: Unlisted Binary Package OS: Linux The following javascript errors are reported: Error: http://www.orange.co.il/catalog/inc/arr.aspx: SyntaxError: Parse error at line 511 Error: http://www.orange.co.il/catalog/inc/mobtbl.aspx: SyntaxError: Parse error at line 465 Error: http://www.orange.co.il/catalog/: SyntaxError: Parse error at line 114 Error: http://www.orange.co.il/global_functions/inc/Menu2.asp: Error: DOM Exception 1 The orange button in the middle of the page causes for each press: Error: node : ReferenceError: Can't find variable: start1
I can confirm those errors and the lines on which they happen look innocent enough. r500000
The first one is: ERROR: syntax error, unexpected RESERVED, expecting IDENT at line 511
If we drop package and goto from list of reserved words, we seem to work, although we still get some parse errors. Mozilla doesn't throw parse errors, it seems, but still doesn't work :-)
SVN commit 514698 by orlovich: Better addRule emulation: unpassed last parameter, -1, etc. mean to append, not to throw an exception CCBUG:120925 M +7 -1 kjs_css.cpp --- branches/KDE/3.5/kdelibs/khtml/ecma/kjs_css.cpp #514697:514698 @@ -550,8 +550,14 @@ return Undefined(); // IE extensions case DOMCSSStyleSheet::AddRule: { + //Unpassed/-1 means append. Since insertRule is picky (throws exceptions) + //we adjust it to the desired length + unsigned long index = args[2].toInteger(exec); + unsigned long length = styleSheet.cssRules().length(); + if (args[2].type() == UndefinedType) index = length; + if (index > length) index = length; DOM::DOMString str = args[0].toString(exec).string() + " { " + args[1].toString(exec).string() + " } "; - return Number(styleSheet.insertRule(str,(long unsigned int)args[2].toInteger(exec))); + return Number(styleSheet.insertRule(str,index)); } case DOMCSSStyleSheet::RemoveRule: { int index = args.size() > 0 ? args[0].toInteger(exec) : 0 /*first one*/;
*** Bug 96743 has been marked as a duplicate of this bug. ***
SVN commit 515499 by orlovich: Free up some "future reserved keywords" for use as identifiers to match IE + mozilla. Fixes #120925 Oh, and it's cool when we render sites mozilla can't :-) BUG:120925 M +27 -23 keywords.table --- branches/KDE/3.5/kdelibs/kjs/keywords.table #515498:515499 @@ -32,35 +32,39 @@ typeof TYPEOF with WITH # reserved for future use -abstract RESERVED -boolean RESERVED -byte RESERVED -char RESERVED class RESERVED debugger RESERVED -double RESERVED enum RESERVED export RESERVED extends RESERVED -final RESERVED -float RESERVED -goto RESERVED -implements RESERVED import RESERVED -int RESERVED -interface RESERVED -long RESERVED -native RESERVED -package RESERVED -private RESERVED -protected RESERVED -public RESERVED -short RESERVED -static RESERVED super RESERVED -synchronized RESERVED -throws RESERVED -transient RESERVED -volatile RESERVED +# All of the following are reserved for future use as per +# ECMA-262, but are permitted as identifiers by both of +# the widespread browsers. +# +#abstract RESERVED +#boolean RESERVED +#byte RESERVED +#char RESERVED +#double RESERVED +#final RESERVED +#float RESERVED +#goto RESERVED +#implements RESERVED +#int RESERVED +#interface RESERVED +#long RESERVED +#native RESERVED +#package RESERVED +#private RESERVED +#protected RESERVED +#public RESERVED +#short RESERVED +#static RESERVED +#synchronized RESERVED +#throws RESERVED +#transient RESERVED +#volatile RESERVED @end