I have a string, and I need to get its first character.
var x = \'somestring\';
alert(x[0]); //in ie7 returns undefined
How can I fix my co
x.substring(0,1)
substring(start, end) extracts the characters from a string, between the 2 indices "start" and "end", not including "end" itself.