$ ( "INPUT [type = 'Number']") keyDown (function (E) {.
var code = the parseInt (e.keyCode);
IF (code> = 96 && code <= 105 || code> = 48 && code <|| code 57 is == =. 8) {
return to true;
} the else {
return to false;
}
})
// text box input event, any non-integer inputs are reset. 1
$ ( "iNPUT [type = 'Number '] "). the bind (" INPUT propertyChange ", function () {
IF (isNaN (parseFloat ($ (the this) .val ())) || parseFloat ($ (the this) .val ()) <= 0) {
$ (the this) .val (0);
} the else {
$ (the this) .val (the parseInt ($ (the this) .val ()));
}
})