var str="我.....我是一个个......帅帅帅帅哥!";
var reg=/\./gi;
str=str.replace(reg,"");
reg=/(.)\1+/gi;
alert(str.replace(reg,"$1"));
转载于:https://www.cnblogs.com/wxc1/p/6114393.html
var str="我.....我是一个个......帅帅帅帅哥!";
var reg=/\./gi;
str=str.replace(reg,"");
reg=/(.)\1+/gi;
alert(str.replace(reg,"$1"));
转载于:https://www.cnblogs.com/wxc1/p/6114393.html