开发者

onKeyUp event is not working in IE but works in firefox

I m trying to get what user type in text box with javascript so i used this

HTML:

JAVASCRIPT: function textTrack(e) { 开发者_StackOverflow中文版 alert(e.keyCode); }

this works fine in firefox but not in IE.


In MSIE use the global event-object:

alert(window.event.keyCode);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜