keycode - How to detect three pressed keys on keybord by jquery and javascript -
this question has answer here:
i need detect keys pressed in keyboard action upon that
wrote script
$(document).keyup(function(e){ var map = {18: false, 17: false, 65: false}; if (e.keycode in map) { map[e.keycode] = true; if (map[18] && map[17] && map[65]) { alert("pressed alt+ctrl+a"); } } });
but script doesn't work
can on me in please
the e
object provide e.ctrlkey
aswell e.altkey
, e.shiftkey
you need test this: e.ctrlkey && e.altkey && e.which == 65
Comments
Post a Comment