Skip to content

Instantly share code, notes, and snippets.

@yannisxu
Created April 8, 2013 07:35
Show Gist options
  • Save yannisxu/5334928 to your computer and use it in GitHub Desktop.
Save yannisxu/5334928 to your computer and use it in GitHub Desktop.
javascript string replaceall method
//method1
mystring.replace(/\./g,' ')
//method2
"abcccc".split("c").join("a")
//method3
str.replace(new RegExp(".","gm")," ")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment