get keycode javascript

by Ramya 2012-05-29 17:55:35

get keycode javascript:

get keycode javascript,
function chKey(e){
var e = window.event;
alert(e.keyCode);
}
<input type="text" size=45 onKeyPress="chKey(event)"/>


you can get the keycode on keypress inside the text box.
895
like
0
dislike
0
mail
flag

You must LOGIN to add comments