28 Jan 2011, 1:32pm
/dev/random
by

leave a comment

for() Loops and IE 8

Everything was going smoothly until we got to testing in IE 8, at which point we started seeing errors inside loops.

Turns out IE 8 doesn’t like for() loops written like so:

for( var idx in items ) {

Instead, use the ol’ fashioned way:

for ( var i = 0; i < items.length; i++ ) {

Maybe in IE 9?

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>