jquery function allow only alphabets and space in text box code example
Example: alphabet only in jquery
<script>
$( document ).ready(function() {
$( ".txtOnly" ).keypress(function(e) {
var key = e.keyCode;
if (key >= 48 && key <= 57) { // 0-9
e.preventDefault();
}
});
});
</script>