Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
31 lines (31 sloc) 988 Bytes
<!doctype html>
<html>
<head>
<title>Some jQuery Bind Bonus</title>
</head>
<body>
<h1>jQuery Bind</h1>
<p>
<label for="throttle">On event throttle:</label>
<input id="throttle" />
<span id="throttle-result"></span>
</p>
<p>
<label for="stop">On event stop:</label>
<input id="stop" />
<span id="stop-result"></span>
</p>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></script>
<script src="jquery.bind.js"></script>
<script>
$(function () {
$('#throttle').bindThrottle('keydown', function () {
$('#throttle-result').html($(this).val());
});
$('#stop').bindStop('keydown', function () {
$('#stop-result').html($(this).val());
});
});
</script>
</body>
</html>