title: jQuery - Disable keydown in input and textareas
body: <p>I am using the arrow keys (and A,W,D) to navigate between pages.</p>
  
  <p>How can I disable the keydown function for textareas and inputfields?</p>
  
  <pre>   $(document).keydown(function(e) {
      switch(e.which) {
          case 65:
              leftArrowPressed();
              break;
          case 37:
              leftArrowPressed();
              break;
          case 68:
              rightArrowPressed();
              break;
          case 39:
              rightArrowPressed();
              break;
          case 72:
              homePressed();
              break;
          case 87:
              homePressed();
              break;
      }
  });</pre>