whatsthecodeforthat.com

What's the code for Replace Substring in javascript?

var replaced = s.replace(old, new);