regexp replace one or more dots with dot code example Example: regular expression replace a dot mystring = mystring.replace(/\./g,' ')