jQuery Alert When Left Arrow is Pressed
HTML
<p>
Click this white box before pressing the left arrow key. You may need to refresh (F5).
</p>
JavaScript
$(document).keydown(function(e){
if (e.keyCode == 37) {
alert( "Left Arrow Pressed" );
return false;
}
});