I have to prevent Coldfusion\'s default list delimiter \',\' from being entered into a form input array. I am new to using javascript for validation purposes, and have never tri
Imho, there's no need to check those keyCodes:
$(document).ready(function(event){ $('#fieldName').keyup(function(event) { var cleanedValue = $(this).val().replace(",","~"); $(this).val(cleanedValue); }); });
Check it on jsFiddle.