Replace All

Fixes issue #1 by using a RegExp with the global flag set