String.fromCharCode(72) gives H. How to get number 72 from char H?
+4
A:
Use charCodeAt:
var str = 'H';
var charcode = str.charCodeAt(0);
Tatu Ulmanen
2010-01-15 13:09:36