jquery keypress call function code example
Example: how to call function on every keypress in jquery
$("#inputFoodChoice").keyup(function (e) {
var code = (e.keyCode ? e.keyCode : e.which);
if (code == 13) { //Enter keycode
e.preventDefault();
checkInputValue(e);
}
});