var re = /,|!|\.|\?/g; var str = "Моя,, супер!!! стро???ка для..!тес,т!?а"; var newstr = str.replace(re, "+")