alert('10 12 14 16'.replace(/d+/g,function(match){
return parseInt(match,10) > 10 ? '*' : match;
}));
这样就可以筛选出有条件的数据了
alert('10 12 14 16'.replace(/d+/g,function(match){
return parseInt(match,10) > 10 ? '*' : match;
}));
这样就可以筛选出有条件的数据了
转载于:https://www.cnblogs.com/jlienzen/p/4169543.html