had a few issues

fixed by adding a for loop to the string replacement.