php replace character in string and return code example Example: php replace str_replace ($search, $replace, $subject);