Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript allow only alphanumeric characters

$('#MyTextInput').on('propertychange input', function () {
  let result = $(this).val().replace(/[^0-9a-z]/gi, '');
  $(this).val(result);
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #alphanumeric #characters
ADD COMMENT
Topic
Name
7+4 =