Answers for "java script how to not allow soace"

0

java script how to not allow soace

$(function() {
        $('#input1').on('keypress', function(e) {
            if (e.which == 32){
                console.log('Space Detected');
                return false;
            }
        });
});
Posted by: Guest on March-23-2020

Code answers related to "java script how to not allow soace"

Code answers related to "Javascript"

Browse Popular Code Answers by Language