var regexp = /[^d,]*/g; newstr=str.replace(regexp,””); 只匹配数字(d)和英文状态下的逗号(,) 注:^在方括号表达式中使用,此时它表示不接受该字 ...

关注我们的公众号

微信公众号