Compsoft Flexible Specialists

Compsoft plc

Compsoft Weblog Compsoft Website News Archive Privacy Policy Contact Us  

Monday, August 24, 2009

JavaScript string handling - oh come on, IE!

Anyone want to guess what the result of this bit of javascript is?

var myString = "abc";
alert(myString[2]);


Let's see, shall we?



Firefox:





Google Chrome:





Safari:





IE7:





Admittedly IE8 treats strings the same way everyone has been treating them since the 1970s, but at the rate users pick up the newer versions, we're going to have to carry this around for a good many years yet.



Sigh.

0 Comments:

Post a Comment

<< Home