Why isit when I do
var footnoteLinks = [1,2,3];
for (var i in footnoteLinks) {
document.write(footnoteLinks[i] + ", ");
}
What I get is something like ...
1, 2, 3, function () { return lower; }, function Array() { [native code] }, function pop() { [native code] }, function push() { [native code] }, function reverse() { [native code] }, function shift() { [native code] }, function sort() { [native code] }, function splice() { [native code] }, function unshift()
Why is that? Whats with the functions etc... I think it worked ok b4, I dunno what caused this now, it seems the same for all browsers I tried. Firefox 3.6, Chrome 6 (i think?), IE9
for .. inwithout ahasOwnPropertycheck - and the old-style loops are very significantly faster thanfor .. in .. hasOwnProperty.