replace a dot in regex code example Example: regular expression replace a dot mystring = mystring.replace(/\./g,' ')