How can I check to see if there is, or not, a comma (,) in a textbox value? (JavaScript)
Thanks!
Printable View
How can I check to see if there is, or not, a comma (,) in a textbox value? (JavaScript)
Thanks!
Code:function test(val){
str = new String(val);
return str.search(/,/); // -1 if not found
}