Corrected the replace string method by chop the word with a space after.