Replace String in PHP With str_replace Function
Replacing Parts of String With str_replace Function
$string = "I like to eat.";
echo $string; //
I like to eat
$string = str_replace("eat","drink juice", $string);
New output is:
I like to drink juice.