I want to create a code in PHP in which the user type, for example, "pedro went to the market" he replaced in a few words already registered type to exchange the syllable "mer" for copper and the syllable "went" for example. and give the text ready in another window.
I do not know where to start, any help and welcome