Is there a way to translate the charCode
into the actual character that was typed?
For example, if the letter A
is entered on a keyboard, how can PHP output the letter A
instead of its charCode value?
var ucode = function(s) {
var len = s.length;
var rs = "";
for ( var i = 0; i < len; i++) {
var k = s.substring(i, i + 1);
rs += "$" + (s.charCodeAt(i) + "1") + ";";
}
return rs;
};