Created
April 19, 2010 19:23
-
-
Save house9/371466 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Testing</title> | |
<style type="text/css" media="screen"> | |
body { | |
font-family: Verdana; | |
} | |
</style> | |
<script src="jquery-1.4.2.min.js" type="text/javascript" charset="utf-8"></script> | |
<script type="text/javascript"> | |
// $(document).bind('keydown, keypress', function(event) { | |
// console.debug(event.keyCode + " - " + event.which); | |
// // $('#stuff-it').val(event.keyCode + " - " + event.which + "\n" + $('#stuff-it').val()); | |
// // console.debug(event.keyCode); | |
// //event.preventDefault(); | |
// // event.stopPropagation(); | |
// return false; | |
// }); | |
// window.onkeydown = function (e){ | |
// if(e.keyCode == 32 || e.keyCode == 37 || e.keyCode == 39) { | |
// return false; | |
// } | |
// } | |
$(document).bind('keydown, keypress', function(e) { | |
var key = (e.keyCode != 0) ? e.keyCode : e.which; | |
// alert(key); | |
if(key == 32 || key == 37 || key == 39) { | |
return false; | |
} | |
}); | |
</script> | |
</head> | |
<body> | |
<form> | |
<input type="text" name="type_here" value="" id="type_here" /> | |
<br /> | |
<br /> | |
<textarea id="stuff-it" style="width: 620px; height: 120px"> | |
</textarea> | |
</form> | |
<div id="this-div"> | |
| |
</div> | |
<p id="paragraph"> | |
This is a paragraph | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
<p> | |
The quick brown fox jumped over the lazy dog. | |
The quick brown fox jumped over the lazy dog. | |
</p> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment