javascript - Overwriting key events -
javascript - Overwriting key events -
how overwrite or remove key events, on website? i'm writing script greasemonkey , want create event on come in button, when press come in button, triggers function on website.
edit 1: here website, need http://lockerz.com/auth/express_signup
one of these 2 should you. used first one, although on told me sec 1 work also. went hammer.
sorry, first 1 wasn't cutting , paste answer. utilize using homecoming up/down arrow command on website. changed identifies keycode 13 instead.
(function() { function keykiller(event) { if (event.keycode == 13 ) { event.cancelbubble = true; event.stoppropagation(); homecoming false; } } window.addeventlistener('keypress', keykiller, true); window.addeventlistener('keydown', keykiller, true); })();
javascript
Comments
Post a Comment