/ Published in: JavaScript

to use this function send in an ASCII character code (use my getKeyCode function)
it will return true if the code corresponds to a printable character (not backspace code - 8, enter code - 13, or "undefined")
it will return true if the code corresponds to a printable character (not backspace code - 8, enter code - 13, or "undefined")
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
function pressedPrintableChar(code) { if (code != 8 && code != 13 && code + "" != "undefined") return true; return false; }
Comments
